Initial Commit
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
|
||||
#ifndef BOOST_MPL_COMPARISON_HPP_INCLUDED
|
||||
#define BOOST_MPL_COMPARISON_HPP_INCLUDED
|
||||
|
||||
// Copyright Aleksey Gurtovoy 2000-2004
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/mpl for documentation.
|
||||
|
||||
// $Id$
|
||||
// $Date$
|
||||
// $Revision$
|
||||
|
||||
#include <boost/mpl/equal_to.hpp>
|
||||
#include <boost/mpl/not_equal_to.hpp>
|
||||
#include <boost/mpl/less.hpp>
|
||||
#include <boost/mpl/greater.hpp>
|
||||
#include <boost/mpl/less_equal.hpp>
|
||||
#include <boost/mpl/greater_equal.hpp>
|
||||
|
||||
#endif // BOOST_MPL_COMPARISON_HPP_INCLUDED
|
||||
@@ -0,0 +1,153 @@
|
||||
// fwd.hpp Forward declarations of Boost.Math distributions.
|
||||
|
||||
// Copyright Paul A. Bristow 2007, 2010, 2012, 2014.
|
||||
// Copyright John Maddock 2007.
|
||||
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt
|
||||
// or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#ifndef BOOST_MATH_DISTRIBUTIONS_FWD_HPP
|
||||
#define BOOST_MATH_DISTRIBUTIONS_FWD_HPP
|
||||
|
||||
// 33 distributions at Boost 1.9.1 after adding hyperexpon and arcsine
|
||||
|
||||
namespace boost{ namespace math{
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class arcsine_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class bernoulli_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class beta_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class binomial_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class cauchy_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class chi_squared_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class exponential_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class extreme_value_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class fisher_f_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class gamma_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class geometric_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class hyperexponential_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class hypergeometric_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class inverse_chi_squared_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class inverse_gamma_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class inverse_gaussian_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class laplace_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class logistic_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class lognormal_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class negative_binomial_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class non_central_beta_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class non_central_chi_squared_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class non_central_f_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class non_central_t_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class normal_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class pareto_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class poisson_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class rayleigh_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class skew_normal_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class students_t_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class triangular_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class uniform_distribution;
|
||||
|
||||
template <class RealType, class Policy>
|
||||
class weibull_distribution;
|
||||
|
||||
}} // namespaces
|
||||
|
||||
#define BOOST_MATH_DECLARE_DISTRIBUTIONS(Type, Policy)\
|
||||
typedef boost::math::arcsine_distribution<Type, Policy> arcsine;\
|
||||
typedef boost::math::bernoulli_distribution<Type, Policy> bernoulli;\
|
||||
typedef boost::math::beta_distribution<Type, Policy> beta;\
|
||||
typedef boost::math::binomial_distribution<Type, Policy> binomial;\
|
||||
typedef boost::math::cauchy_distribution<Type, Policy> cauchy;\
|
||||
typedef boost::math::chi_squared_distribution<Type, Policy> chi_squared;\
|
||||
typedef boost::math::exponential_distribution<Type, Policy> exponential;\
|
||||
typedef boost::math::extreme_value_distribution<Type, Policy> extreme_value;\
|
||||
typedef boost::math::fisher_f_distribution<Type, Policy> fisher_f;\
|
||||
typedef boost::math::gamma_distribution<Type, Policy> gamma;\
|
||||
typedef boost::math::geometric_distribution<Type, Policy> geometric;\
|
||||
typedef boost::math::hypergeometric_distribution<Type, Policy> hypergeometric;\
|
||||
typedef boost::math::inverse_chi_squared_distribution<Type, Policy> inverse_chi_squared;\
|
||||
typedef boost::math::inverse_gaussian_distribution<Type, Policy> inverse_gaussian;\
|
||||
typedef boost::math::inverse_gamma_distribution<Type, Policy> inverse_gamma;\
|
||||
typedef boost::math::laplace_distribution<Type, Policy> laplace;\
|
||||
typedef boost::math::logistic_distribution<Type, Policy> logistic;\
|
||||
typedef boost::math::lognormal_distribution<Type, Policy> lognormal;\
|
||||
typedef boost::math::negative_binomial_distribution<Type, Policy> negative_binomial;\
|
||||
typedef boost::math::non_central_beta_distribution<Type, Policy> non_central_beta;\
|
||||
typedef boost::math::non_central_chi_squared_distribution<Type, Policy> non_central_chi_squared;\
|
||||
typedef boost::math::non_central_f_distribution<Type, Policy> non_central_f;\
|
||||
typedef boost::math::non_central_t_distribution<Type, Policy> non_central_t;\
|
||||
typedef boost::math::normal_distribution<Type, Policy> normal;\
|
||||
typedef boost::math::pareto_distribution<Type, Policy> pareto;\
|
||||
typedef boost::math::poisson_distribution<Type, Policy> poisson;\
|
||||
typedef boost::math::rayleigh_distribution<Type, Policy> rayleigh;\
|
||||
typedef boost::math::skew_normal_distribution<Type, Policy> skew_normal;\
|
||||
typedef boost::math::students_t_distribution<Type, Policy> students_t;\
|
||||
typedef boost::math::triangular_distribution<Type, Policy> triangular;\
|
||||
typedef boost::math::uniform_distribution<Type, Policy> uniform;\
|
||||
typedef boost::math::weibull_distribution<Type, Policy> weibull;
|
||||
|
||||
#endif // BOOST_MATH_DISTRIBUTIONS_FWD_HPP
|
||||
@@ -0,0 +1,27 @@
|
||||
|
||||
#ifndef BOOST_MPL_AUX_CONFIG_FORWARDING_HPP_INCLUDED
|
||||
#define BOOST_MPL_AUX_CONFIG_FORWARDING_HPP_INCLUDED
|
||||
|
||||
// Copyright Aleksey Gurtovoy 2004
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/mpl for documentation.
|
||||
|
||||
// $Id$
|
||||
// $Date$
|
||||
// $Revision$
|
||||
|
||||
#include <boost/mpl/aux_/config/workaround.hpp>
|
||||
|
||||
#if !defined(BOOST_MPL_CFG_NO_NESTED_FORWARDING) \
|
||||
&& !defined(BOOST_MPL_PREPROCESSING_MODE) \
|
||||
&& BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610))
|
||||
|
||||
# define BOOST_MPL_CFG_NO_NESTED_FORWARDING
|
||||
|
||||
#endif
|
||||
|
||||
#endif // BOOST_MPL_AUX_CONFIG_FORWARDING_HPP_INCLUDED
|
||||
@@ -0,0 +1,70 @@
|
||||
//---------------------------------------------------------------------------//
|
||||
// Copyright (c) 2013 Kyle Lutz <kyle.r.lutz@gmail.com>
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0
|
||||
// See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt
|
||||
//
|
||||
// See http://boostorg.github.com/compute for more information.
|
||||
//---------------------------------------------------------------------------//
|
||||
|
||||
#ifndef BOOST_COMPUTE_ALGORITHM_MINMAX_ELEMENT_HPP
|
||||
#define BOOST_COMPUTE_ALGORITHM_MINMAX_ELEMENT_HPP
|
||||
|
||||
#include <utility>
|
||||
|
||||
#include <boost/compute/system.hpp>
|
||||
#include <boost/compute/command_queue.hpp>
|
||||
#include <boost/compute/algorithm/max_element.hpp>
|
||||
#include <boost/compute/algorithm/min_element.hpp>
|
||||
|
||||
namespace boost {
|
||||
namespace compute {
|
||||
|
||||
/// Returns a pair of iterators with the first pointing to the minimum
|
||||
/// element and the second pointing to the maximum element in the range
|
||||
/// [\p first, \p last).
|
||||
///
|
||||
/// \param first first element in the input range
|
||||
/// \param last last element in the input range
|
||||
/// \param compare comparison function object which returns true if the first
|
||||
/// argument is less than (i.e. is ordered before) the second.
|
||||
/// \param queue command queue to perform the operation
|
||||
///
|
||||
/// \see max_element(), min_element()
|
||||
template<class InputIterator, class Compare>
|
||||
inline std::pair<InputIterator, InputIterator>
|
||||
minmax_element(InputIterator first,
|
||||
InputIterator last,
|
||||
Compare compare,
|
||||
command_queue &queue = system::default_queue())
|
||||
{
|
||||
if(first == last){
|
||||
// empty range
|
||||
return std::make_pair(first, first);
|
||||
}
|
||||
|
||||
return std::make_pair(min_element(first, last, compare, queue),
|
||||
max_element(first, last, compare, queue));
|
||||
}
|
||||
|
||||
///\overload
|
||||
template<class InputIterator>
|
||||
inline std::pair<InputIterator, InputIterator>
|
||||
minmax_element(InputIterator first,
|
||||
InputIterator last,
|
||||
command_queue &queue = system::default_queue())
|
||||
{
|
||||
if(first == last){
|
||||
// empty range
|
||||
return std::make_pair(first, first);
|
||||
}
|
||||
|
||||
return std::make_pair(min_element(first, last, queue),
|
||||
max_element(first, last, queue));
|
||||
}
|
||||
|
||||
} // end compute namespace
|
||||
} // end boost namespace
|
||||
|
||||
#endif // BOOST_COMPUTE_ALGORITHM_MINMAX_ELEMENT_HPP
|
||||
@@ -0,0 +1,55 @@
|
||||
// (C) Copyright 2009-2011 Frederic Bron.
|
||||
//
|
||||
// Use, modification and distribution are subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt).
|
||||
//
|
||||
// See http://www.boost.org/libs/type_traits for most recent version including documentation.
|
||||
|
||||
#ifndef BOOST_TT_HAS_RIGHT_SHIFT_ASSIGN_HPP_INCLUDED
|
||||
#define BOOST_TT_HAS_RIGHT_SHIFT_ASSIGN_HPP_INCLUDED
|
||||
|
||||
#define BOOST_TT_TRAIT_NAME has_right_shift_assign
|
||||
#define BOOST_TT_TRAIT_OP >>=
|
||||
#define BOOST_TT_FORBIDDEN_IF\
|
||||
(\
|
||||
/* Lhs==fundamental and Rhs==fundamental and (Lhs!=integral or Rhs!=integral) */\
|
||||
(\
|
||||
::boost::is_fundamental< Lhs_nocv >::value && \
|
||||
::boost::is_fundamental< Rhs_nocv >::value && \
|
||||
( \
|
||||
(! ::boost::is_integral< Lhs_noref >::value ) || \
|
||||
(! ::boost::is_integral< Rhs_noref >::value )\
|
||||
)\
|
||||
)||\
|
||||
/* Lhs==fundamental and Rhs==pointer */\
|
||||
(\
|
||||
::boost::is_fundamental< Lhs_nocv >::value && \
|
||||
::boost::is_pointer< Rhs_noref >::value\
|
||||
)||\
|
||||
/* Rhs==fundamental and Lhs==pointer */\
|
||||
(\
|
||||
::boost::is_fundamental< Rhs_nocv >::value && \
|
||||
::boost::is_pointer< Lhs_noref >::value\
|
||||
)||\
|
||||
/* Lhs==pointer and Rhs==pointer */\
|
||||
(\
|
||||
::boost::is_pointer< Lhs_noref >::value && \
|
||||
::boost::is_pointer< Rhs_noref >::value\
|
||||
)||\
|
||||
/* Lhs==fundamental and Rhs==fundamental and Lhs==const */\
|
||||
(\
|
||||
::boost::is_fundamental< Lhs_nocv >::value && \
|
||||
::boost::is_fundamental< Rhs_nocv >::value && \
|
||||
::boost::is_const< Lhs_noref >::value\
|
||||
)\
|
||||
)
|
||||
|
||||
|
||||
#include <boost/type_traits/detail/has_binary_operator.hpp>
|
||||
|
||||
#undef BOOST_TT_TRAIT_NAME
|
||||
#undef BOOST_TT_TRAIT_OP
|
||||
#undef BOOST_TT_FORBIDDEN_IF
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,33 @@
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// (C) Copyright Ion Gaztanaga 2014-2015. Distributed under the Boost
|
||||
// Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/container for documentation.
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
#ifndef BOOST_CONTAINER_DETAIL_TO_RAW_POINTER_HPP
|
||||
#define BOOST_CONTAINER_DETAIL_TO_RAW_POINTER_HPP
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_PRAGMA_ONCE)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
#include <boost/intrusive/detail/to_raw_pointer.hpp>
|
||||
|
||||
namespace boost {
|
||||
namespace container {
|
||||
namespace container_detail {
|
||||
|
||||
using ::boost::intrusive::detail::to_raw_pointer;
|
||||
|
||||
} //namespace container_detail {
|
||||
} //namespace container {
|
||||
} //namespace boost {
|
||||
|
||||
#endif //#ifndef BOOST_CONTAINER_DETAIL_TO_RAW_POINTER_HPP
|
||||
@@ -0,0 +1,72 @@
|
||||
// (C) Copyright Gennadiy Rozental 2001.
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/libs/test for the library home page.
|
||||
//
|
||||
// File : $RCSfile$
|
||||
//
|
||||
// Version : $Revision$
|
||||
//
|
||||
// Description : contains OF_XML Log formatter definition
|
||||
// ***************************************************************************
|
||||
|
||||
#ifndef BOOST_TEST_XML_LOG_FORMATTER_020105GER
|
||||
#define BOOST_TEST_XML_LOG_FORMATTER_020105GER
|
||||
|
||||
// Boost.Test
|
||||
#include <boost/test/detail/global_typedef.hpp>
|
||||
#include <boost/test/unit_test_log_formatter.hpp>
|
||||
|
||||
// STL
|
||||
#include <cstddef> // std::size_t
|
||||
|
||||
#include <boost/test/detail/suppress_warnings.hpp>
|
||||
|
||||
//____________________________________________________________________________//
|
||||
|
||||
namespace boost {
|
||||
namespace unit_test {
|
||||
namespace output {
|
||||
|
||||
// ************************************************************************** //
|
||||
// ************** xml_log_formatter ************** //
|
||||
// ************************************************************************** //
|
||||
|
||||
class xml_log_formatter : public unit_test_log_formatter {
|
||||
public:
|
||||
// Formatter interface
|
||||
void log_start( std::ostream&, counter_t test_cases_amount );
|
||||
void log_finish( std::ostream& );
|
||||
void log_build_info( std::ostream& );
|
||||
|
||||
void test_unit_start( std::ostream&, test_unit const& tu );
|
||||
void test_unit_finish( std::ostream&, test_unit const& tu, unsigned long elapsed );
|
||||
void test_unit_skipped( std::ostream&, test_unit const& tu, const_string reason );
|
||||
|
||||
void log_exception_start( std::ostream&, log_checkpoint_data const&, execution_exception const& ex );
|
||||
void log_exception_finish( std::ostream& );
|
||||
|
||||
void log_entry_start( std::ostream&, log_entry_data const&, log_entry_types let );
|
||||
using unit_test_log_formatter::log_entry_value; // bring base class functions into overload set
|
||||
void log_entry_value( std::ostream&, const_string value );
|
||||
void log_entry_finish( std::ostream& );
|
||||
|
||||
void entry_context_start( std::ostream&, log_level );
|
||||
void log_entry_context( std::ostream&, const_string );
|
||||
void entry_context_finish( std::ostream& );
|
||||
|
||||
private:
|
||||
// Data members
|
||||
const_string m_curr_tag;
|
||||
bool m_value_closed;
|
||||
};
|
||||
|
||||
} // namespace output
|
||||
} // namespace unit_test
|
||||
} // namespace boost
|
||||
|
||||
#include <boost/test/detail/enable_warnings.hpp>
|
||||
|
||||
#endif // BOOST_TEST_XML_LOG_FORMATTER_020105GER
|
||||
Binary file not shown.
@@ -0,0 +1,68 @@
|
||||
subroutine cpolyfitw(c,pp,id,maxn,aa,bb,zz,nhardsync)
|
||||
|
||||
include 'wsprlf_params.f90'
|
||||
|
||||
complex c(0:NZ-1) !Complex waveform
|
||||
complex zz(NS+ND) !Complex symbol values (intermediate)
|
||||
complex z,z0
|
||||
real x(NS),yi(NS),yq(NS) !For complex polyfit
|
||||
real pp(2*NSPS) !Shaped pulse for OQPSK
|
||||
real aa(20),bb(20) !Fitted polyco's
|
||||
integer id(NS+ND) !NRZ values (+/-1) for Sync and Data
|
||||
|
||||
ib=NSPS-1
|
||||
ib2=N2-1
|
||||
n=0
|
||||
jz=(NS+ND+1)/2
|
||||
do j=1,jz !First-pass demodulation
|
||||
ia=ib+1
|
||||
ib=ia+N2-1
|
||||
zz(j)=sum(pp*c(ia:ib))/NSPS
|
||||
if(abs(id(j)).eq.2) then !Save all sync symbols
|
||||
n=n+1
|
||||
x(n)=float(ia+ib)/NZ - 1.0
|
||||
yi(n)=real(zz(j))*0.5*id(j)
|
||||
yq(n)=aimag(zz(j))*0.5*id(j)
|
||||
! write(54,1225) n,x(n),yi(n),yq(n)
|
||||
!1225 format(i5,3f12.4)
|
||||
endif
|
||||
if(j.lt.jz) then
|
||||
zz(j+jz)=sum(pp*c(ia+NSPS:ib+NSPS))/NSPS
|
||||
endif
|
||||
enddo
|
||||
|
||||
aa=0.
|
||||
bb=0.
|
||||
nterms=0
|
||||
chisqa=0.
|
||||
chisqb=0.
|
||||
if(maxn.gt.0) then
|
||||
npts=n
|
||||
mode=0
|
||||
nterms=maxn
|
||||
call polyfit4(x,yi,yi,npts,nterms,mode,aa,chisqa)
|
||||
call polyfit4(x,yq,yq,npts,nterms,mode,bb,chisqb)
|
||||
endif
|
||||
|
||||
nhardsync=0
|
||||
do j=1,205
|
||||
if(abs(id(j)).ne.2) cycle
|
||||
xx=j*2.0/205.0 - 1.0
|
||||
yii=1.
|
||||
yqq=0.
|
||||
if(nterms.gt.0) then
|
||||
yii=aa(1)
|
||||
yqq=bb(1)
|
||||
do i=2,nterms
|
||||
yii=yii + aa(i)*xx**(i-1)
|
||||
yqq=yqq + bb(i)*xx**(i-1)
|
||||
enddo
|
||||
endif
|
||||
z0=cmplx(yii,yqq)
|
||||
z=zz(j)*conjg(z0)
|
||||
p=real(z)
|
||||
if(p*id(j).lt.0) nhardsync=nhardsync+1
|
||||
enddo
|
||||
|
||||
return
|
||||
end subroutine cpolyfitw
|
||||
@@ -0,0 +1,76 @@
|
||||
// (C) Copyright Jens Maurer 2001.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// Modena C++ standard library (comes with KAI C++)
|
||||
|
||||
#if !defined(MSIPL_COMPILE_H)
|
||||
# include <boost/config/no_tr1/utility.hpp>
|
||||
# if !defined(__MSIPL_COMPILE_H)
|
||||
# error "This is not the Modena C++ library!"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef MSIPL_NL_TYPES
|
||||
#define BOOST_NO_STD_MESSAGES
|
||||
#endif
|
||||
|
||||
#ifndef MSIPL_WCHART
|
||||
#define BOOST_NO_STD_WSTRING
|
||||
#endif
|
||||
|
||||
// C++0x headers not yet implemented
|
||||
//
|
||||
# define BOOST_NO_CXX11_HDR_ARRAY
|
||||
# define BOOST_NO_CXX11_HDR_CHRONO
|
||||
# define BOOST_NO_CXX11_HDR_CODECVT
|
||||
# define BOOST_NO_CXX11_HDR_CONDITION_VARIABLE
|
||||
# define BOOST_NO_CXX11_HDR_FORWARD_LIST
|
||||
# define BOOST_NO_CXX11_HDR_FUTURE
|
||||
# define BOOST_NO_CXX11_HDR_INITIALIZER_LIST
|
||||
# define BOOST_NO_CXX11_HDR_MUTEX
|
||||
# define BOOST_NO_CXX11_HDR_RANDOM
|
||||
# define BOOST_NO_CXX11_HDR_RATIO
|
||||
# define BOOST_NO_CXX11_HDR_REGEX
|
||||
# define BOOST_NO_CXX11_HDR_SYSTEM_ERROR
|
||||
# define BOOST_NO_CXX11_HDR_THREAD
|
||||
# define BOOST_NO_CXX11_HDR_TUPLE
|
||||
# define BOOST_NO_CXX11_HDR_TYPE_TRAITS
|
||||
# define BOOST_NO_CXX11_HDR_TYPEINDEX
|
||||
# define BOOST_NO_CXX11_HDR_UNORDERED_MAP
|
||||
# define BOOST_NO_CXX11_HDR_UNORDERED_SET
|
||||
# define BOOST_NO_CXX11_NUMERIC_LIMITS
|
||||
# define BOOST_NO_CXX11_ALLOCATOR
|
||||
# define BOOST_NO_CXX11_ATOMIC_SMART_PTR
|
||||
# define BOOST_NO_CXX11_SMART_PTR
|
||||
# define BOOST_NO_CXX11_HDR_FUNCTIONAL
|
||||
# define BOOST_NO_CXX11_HDR_ATOMIC
|
||||
# define BOOST_NO_CXX11_STD_ALIGN
|
||||
# define BOOST_NO_CXX11_ADDRESSOF
|
||||
|
||||
#if defined(__has_include)
|
||||
#if !__has_include(<shared_mutex>)
|
||||
# define BOOST_NO_CXX14_HDR_SHARED_MUTEX
|
||||
#elif __cplusplus < 201402
|
||||
# define BOOST_NO_CXX14_HDR_SHARED_MUTEX
|
||||
#endif
|
||||
#else
|
||||
# define BOOST_NO_CXX14_HDR_SHARED_MUTEX
|
||||
#endif
|
||||
|
||||
// C++14 features
|
||||
# define BOOST_NO_CXX14_STD_EXCHANGE
|
||||
|
||||
// C++17 features
|
||||
# define BOOST_NO_CXX17_STD_APPLY
|
||||
# define BOOST_NO_CXX17_STD_INVOKE
|
||||
|
||||
#define BOOST_STDLIB "Modena C++ standard library"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,105 @@
|
||||
// Boost compiler configuration selection header file
|
||||
|
||||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright Jens Maurer 2001 - 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// locate which std lib we are using and define BOOST_STDLIB_CONFIG as needed:
|
||||
|
||||
// First include <cstddef> to determine if some version of STLport is in use as the std lib
|
||||
// (do not rely on this header being included since users can short-circuit this header
|
||||
// if they know whose std lib they are using.)
|
||||
#ifdef __cplusplus
|
||||
# include <cstddef>
|
||||
#else
|
||||
# include <stddef.h>
|
||||
#endif
|
||||
|
||||
#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
|
||||
// STLPort library; this _must_ come first, otherwise since
|
||||
// STLport typically sits on top of some other library, we
|
||||
// can end up detecting that first rather than STLport:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/stlport.hpp"
|
||||
|
||||
#else
|
||||
|
||||
// If our std lib was not some version of STLport, and has not otherwise
|
||||
// been detected, then include <utility> as it is about
|
||||
// the smallest of the std lib headers that includes real C++ stuff.
|
||||
// Some std libs do not include their C++-related macros in <cstddef>
|
||||
// so this additional include makes sure we get those definitions.
|
||||
// Note: do not rely on this header being included since users can short-circuit this
|
||||
// #include if they know whose std lib they are using.
|
||||
#if !defined(__LIBCOMO__) && !defined(__STD_RWCOMPILER_H__) && !defined(_RWSTD_VER)\
|
||||
&& !defined(_LIBCPP_VERSION) && !defined(__GLIBCPP__) && !defined(__GLIBCXX__)\
|
||||
&& !defined(__STL_CONFIG_H) && !defined(__MSL_CPP__) && !defined(__IBMCPP__)\
|
||||
&& !defined(MSIPL_COMPILE_H) && !defined(_YVALS) && !defined(_CPPLIB_VER)
|
||||
#include <utility>
|
||||
#endif
|
||||
|
||||
#if defined(__LIBCOMO__)
|
||||
// Comeau STL:
|
||||
#define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcomo.hpp"
|
||||
|
||||
#elif defined(__STD_RWCOMPILER_H__) || defined(_RWSTD_VER)
|
||||
// Rogue Wave library:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/roguewave.hpp"
|
||||
|
||||
#elif defined(_LIBCPP_VERSION)
|
||||
// libc++
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libcpp.hpp"
|
||||
|
||||
#elif defined(__GLIBCPP__) || defined(__GLIBCXX__)
|
||||
// GNU libstdc++ 3
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/libstdcpp3.hpp"
|
||||
|
||||
#elif defined(__STL_CONFIG_H)
|
||||
// generic SGI STL
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/sgi.hpp"
|
||||
|
||||
#elif defined(__MSL_CPP__)
|
||||
// MSL standard lib:
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/msl.hpp"
|
||||
|
||||
#elif defined(__IBMCPP__)
|
||||
// take the default VACPP std lib
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/vacpp.hpp"
|
||||
|
||||
#elif defined(MSIPL_COMPILE_H)
|
||||
// Modena C++ standard library
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/modena.hpp"
|
||||
|
||||
#elif (defined(_YVALS) && !defined(__IBMCPP__)) || defined(_CPPLIB_VER)
|
||||
// Dinkumware Library (this has to appear after any possible replacement libraries):
|
||||
# define BOOST_STDLIB_CONFIG "boost/config/stdlib/dinkumware.hpp"
|
||||
|
||||
#elif defined (BOOST_ASSERT_CONFIG)
|
||||
// this must come last - generate an error if we don't
|
||||
// recognise the library:
|
||||
# error "Unknown standard library - please configure and report the results to boost.org"
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
//
|
||||
// This section allows dependency scanners to find all the files we *might* include:
|
||||
//
|
||||
# include "boost/config/stdlib/stlport.hpp"
|
||||
# include "boost/config/stdlib/libcomo.hpp"
|
||||
# include "boost/config/stdlib/roguewave.hpp"
|
||||
# include "boost/config/stdlib/libcpp.hpp"
|
||||
# include "boost/config/stdlib/libstdcpp3.hpp"
|
||||
# include "boost/config/stdlib/sgi.hpp"
|
||||
# include "boost/config/stdlib/msl.hpp"
|
||||
# include "boost/config/stdlib/vacpp.hpp"
|
||||
# include "boost/config/stdlib/modena.hpp"
|
||||
# include "boost/config/stdlib/dinkumware.hpp"
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
# /* **************************************************************************
|
||||
# * *
|
||||
# * (C) Copyright Edward Diener 2013.
|
||||
# * Distributed under the Boost Software License, Version 1.0. (See
|
||||
# * accompanying file LICENSE_1_0.txt or copy at
|
||||
# * http://www.boost.org/LICENSE_1_0.txt)
|
||||
# * *
|
||||
# ************************************************************************** */
|
||||
#
|
||||
# /* See http://www.boost.org for most recent version. */
|
||||
#
|
||||
# ifndef BOOST_PREPROCESSOR_TUPLE_INSERT_HPP
|
||||
# define BOOST_PREPROCESSOR_TUPLE_INSERT_HPP
|
||||
#
|
||||
# include <boost/preprocessor/config/config.hpp>
|
||||
#
|
||||
# if BOOST_PP_VARIADICS
|
||||
#
|
||||
# include <boost/preprocessor/array/insert.hpp>
|
||||
# include <boost/preprocessor/array/to_tuple.hpp>
|
||||
# include <boost/preprocessor/tuple/to_array.hpp>
|
||||
#
|
||||
# /* BOOST_PP_TUPLE_INSERT */
|
||||
#
|
||||
# define BOOST_PP_TUPLE_INSERT(tuple, i, elem) \
|
||||
BOOST_PP_ARRAY_TO_TUPLE(BOOST_PP_ARRAY_INSERT(BOOST_PP_TUPLE_TO_ARRAY(tuple), i, elem)) \
|
||||
/**/
|
||||
#
|
||||
# /* BOOST_PP_TUPLE_INSERT_D */
|
||||
#
|
||||
# define BOOST_PP_TUPLE_INSERT_D(d, tuple, i, elem) \
|
||||
BOOST_PP_ARRAY_TO_TUPLE(BOOST_PP_ARRAY_INSERT_D(d, BOOST_PP_TUPLE_TO_ARRAY(tuple), i, elem)) \
|
||||
/**/
|
||||
#
|
||||
# endif // BOOST_PP_VARIADICS
|
||||
#
|
||||
# endif // BOOST_PREPROCESSOR_TUPLE_INSERT_HPP
|
||||
@@ -0,0 +1,131 @@
|
||||
/* Copyright 2003-2015 Joaquin M Lopez Munoz.
|
||||
* Distributed under the Boost Software License, Version 1.0.
|
||||
* (See accompanying file LICENSE_1_0.txt or copy at
|
||||
* http://www.boost.org/LICENSE_1_0.txt)
|
||||
*
|
||||
* See http://www.boost.org/libs/multi_index for library home page.
|
||||
*/
|
||||
|
||||
#ifndef BOOST_MULTI_INDEX_DETAIL_INDEX_NODE_BASE_HPP
|
||||
#define BOOST_MULTI_INDEX_DETAIL_INDEX_NODE_BASE_HPP
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#pragma once
|
||||
#endif
|
||||
|
||||
#include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
|
||||
#include <boost/type_traits/aligned_storage.hpp>
|
||||
#include <boost/type_traits/alignment_of.hpp>
|
||||
|
||||
#if !defined(BOOST_MULTI_INDEX_DISABLE_SERIALIZATION)
|
||||
#include <boost/archive/archive_exception.hpp>
|
||||
#include <boost/serialization/access.hpp>
|
||||
#include <boost/throw_exception.hpp>
|
||||
#endif
|
||||
|
||||
namespace boost{
|
||||
|
||||
namespace multi_index{
|
||||
|
||||
namespace detail{
|
||||
|
||||
/* index_node_base tops the node hierarchy of multi_index_container. It holds
|
||||
* the value of the element contained.
|
||||
*/
|
||||
|
||||
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; /* used for serialization purposes */
|
||||
typedef Value value_type;
|
||||
typedef Allocator allocator_type;
|
||||
|
||||
value_type& value()
|
||||
{
|
||||
return *reinterpret_cast<value_type*>(&this->space);
|
||||
}
|
||||
|
||||
const value_type& value()const
|
||||
{
|
||||
return *reinterpret_cast<const value_type*>(&this->space);
|
||||
}
|
||||
|
||||
static index_node_base* from_value(const value_type* p)
|
||||
{
|
||||
return static_cast<index_node_base *>(
|
||||
reinterpret_cast<pod_value_holder<Value>*>( /* std 9.2.17 */
|
||||
const_cast<value_type*>(p)));
|
||||
}
|
||||
|
||||
private:
|
||||
#if !defined(BOOST_MULTI_INDEX_DISABLE_SERIALIZATION)
|
||||
friend class boost::serialization::access;
|
||||
|
||||
/* nodes do not emit any kind of serialization info. They are
|
||||
* fed to Boost.Serialization so that pointers to nodes are
|
||||
* tracked correctly.
|
||||
*/
|
||||
|
||||
template<class Archive>
|
||||
void serialize(Archive&,const unsigned int)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
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));
|
||||
}
|
||||
|
||||
} /* namespace multi_index::detail */
|
||||
|
||||
} /* namespace multi_index */
|
||||
|
||||
#if !defined(BOOST_MULTI_INDEX_DISABLE_SERIALIZATION)
|
||||
/* Index nodes never get constructed directly by Boost.Serialization,
|
||||
* as archives are always fed pointers to previously existent
|
||||
* nodes. So, if this is called it means we are dealing with a
|
||||
* somehow invalid archive.
|
||||
*/
|
||||
|
||||
#if defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP)
|
||||
namespace serialization{
|
||||
#else
|
||||
namespace multi_index{
|
||||
namespace detail{
|
||||
#endif
|
||||
|
||||
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));
|
||||
}
|
||||
|
||||
#if defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP)
|
||||
} /* namespace serialization */
|
||||
#else
|
||||
} /* namespace multi_index::detail */
|
||||
} /* namespace multi_index */
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
} /* namespace boost */
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,99 @@
|
||||
# /* **************************************************************************
|
||||
# * *
|
||||
# * (C) Copyright Paul Mensonides 2002.
|
||||
# * Distributed under the Boost Software License, Version 1.0. (See
|
||||
# * accompanying file LICENSE_1_0.txt or copy at
|
||||
# * http://www.boost.org/LICENSE_1_0.txt)
|
||||
# * *
|
||||
# ************************************************************************** */
|
||||
#
|
||||
# /* See http://www.boost.org for most recent version. */
|
||||
#
|
||||
# include <boost/preprocessor/slot/detail/shared.hpp>
|
||||
#
|
||||
# undef BOOST_PP_ITERATION_START_4
|
||||
#
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_1
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_2
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_3
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_4
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_5
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_6
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_7
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_8
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_9
|
||||
# undef BOOST_PP_ITERATION_START_4_DIGIT_10
|
||||
#
|
||||
# if BOOST_PP_SLOT_TEMP_3 == 0
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 0
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 1
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 1
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 2
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 2
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 3
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 3
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 4
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 4
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 5
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 5
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 6
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 6
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 7
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 7
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 8
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 8
|
||||
# elif BOOST_PP_SLOT_TEMP_3 == 9
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_3 9
|
||||
# endif
|
||||
#
|
||||
# if BOOST_PP_SLOT_TEMP_2 == 0
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 0
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 1
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 1
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 2
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 2
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 3
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 3
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 4
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 4
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 5
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 5
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 6
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 6
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 7
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 7
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 8
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 8
|
||||
# elif BOOST_PP_SLOT_TEMP_2 == 9
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_2 9
|
||||
# endif
|
||||
#
|
||||
# if BOOST_PP_SLOT_TEMP_1 == 0
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 0
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 1
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 1
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 2
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 2
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 3
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 3
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 4
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 4
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 5
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 5
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 6
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 6
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 7
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 7
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 8
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 8
|
||||
# elif BOOST_PP_SLOT_TEMP_1 == 9
|
||||
# define BOOST_PP_ITERATION_START_4_DIGIT_1 9
|
||||
# endif
|
||||
#
|
||||
# if BOOST_PP_ITERATION_START_4_DIGIT_3
|
||||
# define BOOST_PP_ITERATION_START_4 BOOST_PP_SLOT_CC_3(BOOST_PP_ITERATION_START_4_DIGIT_3, BOOST_PP_ITERATION_START_4_DIGIT_2, BOOST_PP_ITERATION_START_4_DIGIT_1)
|
||||
# elif BOOST_PP_ITERATION_START_4_DIGIT_2
|
||||
# define BOOST_PP_ITERATION_START_4 BOOST_PP_SLOT_CC_2(BOOST_PP_ITERATION_START_4_DIGIT_2, BOOST_PP_ITERATION_START_4_DIGIT_1)
|
||||
# else
|
||||
# define BOOST_PP_ITERATION_START_4 BOOST_PP_ITERATION_START_4_DIGIT_1
|
||||
# endif
|
||||
@@ -0,0 +1,461 @@
|
||||
// Copyright 2002 The Trustees of Indiana University.
|
||||
|
||||
// Use, modification and distribution is subject to the Boost Software
|
||||
// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// Boost.MultiArray Library
|
||||
// Authors: Ronald Garcia
|
||||
// Jeremy Siek
|
||||
// Andrew Lumsdaine
|
||||
// See http://www.boost.org/libs/multi_array for documentation.
|
||||
|
||||
#ifndef BOOST_MULTI_ARRAY_VIEW_RG071301_HPP
|
||||
#define BOOST_MULTI_ARRAY_VIEW_RG071301_HPP
|
||||
|
||||
//
|
||||
// view.hpp - code for creating "views" of array data.
|
||||
//
|
||||
|
||||
#include "boost/multi_array/base.hpp"
|
||||
#include "boost/multi_array/concept_checks.hpp"
|
||||
#include "boost/multi_array/iterator.hpp"
|
||||
#include "boost/multi_array/storage_order.hpp"
|
||||
#include "boost/multi_array/subarray.hpp"
|
||||
#include "boost/multi_array/algorithm.hpp"
|
||||
#include "boost/type_traits/is_integral.hpp"
|
||||
#include "boost/utility/enable_if.hpp"
|
||||
#include "boost/array.hpp"
|
||||
#include "boost/limits.hpp"
|
||||
#include <algorithm>
|
||||
#include <cstddef>
|
||||
#include <functional>
|
||||
#include <numeric>
|
||||
|
||||
namespace boost {
|
||||
namespace detail {
|
||||
namespace multi_array {
|
||||
|
||||
// TPtr = const T* defaulted in base.hpp
|
||||
template <typename T, std::size_t NumDims, typename TPtr>
|
||||
class const_multi_array_view :
|
||||
public boost::detail::multi_array::multi_array_impl_base<T,NumDims>
|
||||
{
|
||||
typedef boost::detail::multi_array::multi_array_impl_base<T,NumDims> super_type;
|
||||
public:
|
||||
typedef typename super_type::value_type value_type;
|
||||
typedef typename super_type::const_reference const_reference;
|
||||
typedef typename super_type::const_iterator const_iterator;
|
||||
typedef typename super_type::const_reverse_iterator const_reverse_iterator;
|
||||
typedef typename super_type::element element;
|
||||
typedef typename super_type::size_type size_type;
|
||||
typedef typename super_type::difference_type difference_type;
|
||||
typedef typename super_type::index index;
|
||||
typedef typename super_type::extent_range extent_range;
|
||||
|
||||
// template typedefs
|
||||
template <std::size_t NDims>
|
||||
struct const_array_view {
|
||||
typedef boost::detail::multi_array::const_multi_array_view<T,NDims> type;
|
||||
};
|
||||
|
||||
template <std::size_t NDims>
|
||||
struct array_view {
|
||||
typedef boost::detail::multi_array::multi_array_view<T,NDims> type;
|
||||
};
|
||||
|
||||
template <typename OPtr>
|
||||
const_multi_array_view(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& other) :
|
||||
base_(other.base_), origin_offset_(other.origin_offset_),
|
||||
num_elements_(other.num_elements_), extent_list_(other.extent_list_),
|
||||
stride_list_(other.stride_list_), index_base_list_(other.index_base_list_)
|
||||
{ }
|
||||
|
||||
|
||||
template <class BaseList>
|
||||
#ifdef BOOST_NO_SFINAE
|
||||
void
|
||||
#else
|
||||
typename
|
||||
disable_if<typename boost::is_integral<BaseList>::type,void >::type
|
||||
#endif
|
||||
reindex(const BaseList& values) {
|
||||
boost::function_requires<
|
||||
CollectionConcept<BaseList> >();
|
||||
boost::detail::multi_array::
|
||||
copy_n(values.begin(),num_dimensions(),index_base_list_.begin());
|
||||
origin_offset_ =
|
||||
this->calculate_indexing_offset(stride_list_,index_base_list_);
|
||||
}
|
||||
|
||||
void reindex(index value) {
|
||||
index_base_list_.assign(value);
|
||||
origin_offset_ =
|
||||
this->calculate_indexing_offset(stride_list_,index_base_list_);
|
||||
}
|
||||
|
||||
size_type num_dimensions() const { return NumDims; }
|
||||
|
||||
size_type size() const { return extent_list_.front(); }
|
||||
size_type max_size() const { return num_elements(); }
|
||||
bool empty() const { return size() == 0; }
|
||||
|
||||
const size_type* shape() const {
|
||||
return extent_list_.data();
|
||||
}
|
||||
|
||||
const index* strides() const {
|
||||
return stride_list_.data();
|
||||
}
|
||||
|
||||
const T* origin() const { return base_+origin_offset_; }
|
||||
|
||||
size_type num_elements() const { return num_elements_; }
|
||||
|
||||
const index* index_bases() const {
|
||||
return index_base_list_.data();
|
||||
}
|
||||
|
||||
template <typename IndexList>
|
||||
const element& operator()(IndexList indices) const {
|
||||
boost::function_requires<
|
||||
CollectionConcept<IndexList> >();
|
||||
return super_type::access_element(boost::type<const element&>(),
|
||||
indices,origin(),
|
||||
shape(),strides(),index_bases());
|
||||
}
|
||||
|
||||
// Only allow const element access
|
||||
const_reference operator[](index idx) const {
|
||||
return super_type::access(boost::type<const_reference>(),
|
||||
idx,origin(),
|
||||
shape(),strides(),
|
||||
index_bases());
|
||||
}
|
||||
|
||||
// see generate_array_view in base.hpp
|
||||
template <int NDims>
|
||||
typename const_array_view<NDims>::type
|
||||
operator[](const boost::detail::multi_array::
|
||||
index_gen<NumDims,NDims>& indices)
|
||||
const {
|
||||
typedef typename const_array_view<NDims>::type return_type;
|
||||
return
|
||||
super_type::generate_array_view(boost::type<return_type>(),
|
||||
indices,
|
||||
shape(),
|
||||
strides(),
|
||||
index_bases(),
|
||||
origin());
|
||||
}
|
||||
const_iterator begin() const {
|
||||
return const_iterator(*index_bases(),origin(),
|
||||
shape(),strides(),index_bases());
|
||||
}
|
||||
|
||||
const_iterator end() const {
|
||||
return const_iterator(*index_bases()+(index)*shape(),origin(),
|
||||
shape(),strides(),index_bases());
|
||||
}
|
||||
|
||||
const_reverse_iterator rbegin() const {
|
||||
return const_reverse_iterator(end());
|
||||
}
|
||||
|
||||
const_reverse_iterator rend() const {
|
||||
return const_reverse_iterator(begin());
|
||||
}
|
||||
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator==(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
if(std::equal(extent_list_.begin(),
|
||||
extent_list_.end(),
|
||||
rhs.extent_list_.begin()))
|
||||
return std::equal(begin(),end(),rhs.begin());
|
||||
else return false;
|
||||
}
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator<(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
return std::lexicographical_compare(begin(),end(),rhs.begin(),rhs.end());
|
||||
}
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator!=(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
return !(*this == rhs);
|
||||
}
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator>(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
return rhs < *this;
|
||||
}
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator<=(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
return !(*this > rhs);
|
||||
}
|
||||
|
||||
template <typename OPtr>
|
||||
bool operator>=(const
|
||||
const_multi_array_view<T,NumDims,OPtr>& rhs)
|
||||
const {
|
||||
return !(*this < rhs);
|
||||
}
|
||||
|
||||
|
||||
#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
protected:
|
||||
template <typename,std::size_t> friend class multi_array_impl_base;
|
||||
template <typename,std::size_t,typename> friend class const_multi_array_view;
|
||||
#else
|
||||
public: // should be protected
|
||||
#endif
|
||||
|
||||
// This constructor is used by multi_array_impl_base::generate_array_view
|
||||
// to create strides
|
||||
template <typename ExtentList, typename Index>
|
||||
explicit const_multi_array_view(TPtr base,
|
||||
const ExtentList& extents,
|
||||
const boost::array<Index,NumDims>& strides):
|
||||
base_(base), origin_offset_(0) {
|
||||
|
||||
index_base_list_.assign(0);
|
||||
|
||||
// Get the extents and strides
|
||||
boost::detail::multi_array::
|
||||
copy_n(extents.begin(),NumDims,extent_list_.begin());
|
||||
boost::detail::multi_array::
|
||||
copy_n(strides.begin(),NumDims,stride_list_.begin());
|
||||
|
||||
// Calculate the array size
|
||||
num_elements_ = std::accumulate(extent_list_.begin(),extent_list_.end(),
|
||||
size_type(1),std::multiplies<size_type>());
|
||||
}
|
||||
|
||||
typedef boost::array<size_type,NumDims> size_list;
|
||||
typedef boost::array<index,NumDims> index_list;
|
||||
|
||||
TPtr base_;
|
||||
index origin_offset_;
|
||||
size_type num_elements_;
|
||||
size_list extent_list_;
|
||||
index_list stride_list_;
|
||||
index_list index_base_list_;
|
||||
|
||||
private:
|
||||
// const_multi_array_view cannot be assigned to (no deep copies!)
|
||||
const_multi_array_view& operator=(const const_multi_array_view& other);
|
||||
};
|
||||
|
||||
|
||||
template <typename T, std::size_t NumDims>
|
||||
class multi_array_view :
|
||||
public const_multi_array_view<T,NumDims,T*>
|
||||
{
|
||||
typedef const_multi_array_view<T,NumDims,T*> super_type;
|
||||
public:
|
||||
typedef typename super_type::value_type value_type;
|
||||
typedef typename super_type::reference reference;
|
||||
typedef typename super_type::iterator iterator;
|
||||
typedef typename super_type::reverse_iterator reverse_iterator;
|
||||
typedef typename super_type::const_reference const_reference;
|
||||
typedef typename super_type::const_iterator const_iterator;
|
||||
typedef typename super_type::const_reverse_iterator const_reverse_iterator;
|
||||
typedef typename super_type::element element;
|
||||
typedef typename super_type::size_type size_type;
|
||||
typedef typename super_type::difference_type difference_type;
|
||||
typedef typename super_type::index index;
|
||||
typedef typename super_type::extent_range extent_range;
|
||||
|
||||
// template typedefs
|
||||
template <std::size_t NDims>
|
||||
struct const_array_view {
|
||||
typedef boost::detail::multi_array::const_multi_array_view<T,NDims> type;
|
||||
};
|
||||
|
||||
template <std::size_t NDims>
|
||||
struct array_view {
|
||||
typedef boost::detail::multi_array::multi_array_view<T,NDims> type;
|
||||
};
|
||||
|
||||
// Assignment from other ConstMultiArray types.
|
||||
template <typename ConstMultiArray>
|
||||
multi_array_view& operator=(const ConstMultiArray& other) {
|
||||
function_requires<
|
||||
boost::multi_array_concepts::
|
||||
ConstMultiArrayConcept<ConstMultiArray,NumDims> >();
|
||||
|
||||
// make sure the dimensions agree
|
||||
BOOST_ASSERT(other.num_dimensions() == this->num_dimensions());
|
||||
BOOST_ASSERT(std::equal(other.shape(),other.shape()+this->num_dimensions(),
|
||||
this->shape()));
|
||||
// iterator-based copy
|
||||
std::copy(other.begin(),other.end(),begin());
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
multi_array_view& operator=(const multi_array_view& other) {
|
||||
if (&other != this) {
|
||||
// make sure the dimensions agree
|
||||
BOOST_ASSERT(other.num_dimensions() == this->num_dimensions());
|
||||
BOOST_ASSERT(std::equal(other.shape(),
|
||||
other.shape()+this->num_dimensions(),
|
||||
this->shape()));
|
||||
// iterator-based copy
|
||||
std::copy(other.begin(),other.end(),begin());
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
element* origin() { return this->base_+this->origin_offset_; }
|
||||
|
||||
template <class IndexList>
|
||||
element& operator()(const IndexList& indices) {
|
||||
boost::function_requires<
|
||||
CollectionConcept<IndexList> >();
|
||||
return super_type::access_element(boost::type<element&>(),
|
||||
indices,origin(),
|
||||
this->shape(),this->strides(),
|
||||
this->index_bases());
|
||||
}
|
||||
|
||||
|
||||
reference operator[](index idx) {
|
||||
return super_type::access(boost::type<reference>(),
|
||||
idx,origin(),
|
||||
this->shape(),this->strides(),
|
||||
this->index_bases());
|
||||
}
|
||||
|
||||
|
||||
// see generate_array_view in base.hpp
|
||||
template <int NDims>
|
||||
typename array_view<NDims>::type
|
||||
operator[](const boost::detail::multi_array::
|
||||
index_gen<NumDims,NDims>& indices) {
|
||||
typedef typename array_view<NDims>::type return_type;
|
||||
return
|
||||
super_type::generate_array_view(boost::type<return_type>(),
|
||||
indices,
|
||||
this->shape(),
|
||||
this->strides(),
|
||||
this->index_bases(),
|
||||
origin());
|
||||
}
|
||||
|
||||
|
||||
iterator begin() {
|
||||
return iterator(*this->index_bases(),origin(),
|
||||
this->shape(),this->strides(),
|
||||
this->index_bases());
|
||||
}
|
||||
|
||||
iterator end() {
|
||||
return iterator(*this->index_bases()+(index)*this->shape(),origin(),
|
||||
this->shape(),this->strides(),
|
||||
this->index_bases());
|
||||
}
|
||||
|
||||
reverse_iterator rbegin() {
|
||||
return reverse_iterator(end());
|
||||
}
|
||||
|
||||
reverse_iterator rend() {
|
||||
return reverse_iterator(begin());
|
||||
}
|
||||
|
||||
// Using declarations don't seem to work for g++
|
||||
// These are the proxies to work around this.
|
||||
|
||||
const element* origin() const { return super_type::origin(); }
|
||||
|
||||
template <class IndexList>
|
||||
const element& operator()(const IndexList& indices) const {
|
||||
boost::function_requires<
|
||||
CollectionConcept<IndexList> >();
|
||||
return super_type::operator()(indices);
|
||||
}
|
||||
|
||||
const_reference operator[](index idx) const {
|
||||
return super_type::operator[](idx);
|
||||
}
|
||||
|
||||
// see generate_array_view in base.hpp
|
||||
template <int NDims>
|
||||
typename const_array_view<NDims>::type
|
||||
operator[](const boost::detail::multi_array::
|
||||
index_gen<NumDims,NDims>& indices)
|
||||
const {
|
||||
return super_type::operator[](indices);
|
||||
}
|
||||
|
||||
const_iterator begin() const {
|
||||
return super_type::begin();
|
||||
}
|
||||
|
||||
const_iterator end() const {
|
||||
return super_type::end();
|
||||
}
|
||||
|
||||
const_reverse_iterator rbegin() const {
|
||||
return super_type::rbegin();
|
||||
}
|
||||
|
||||
const_reverse_iterator rend() const {
|
||||
return super_type::rend();
|
||||
}
|
||||
|
||||
#ifndef BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
private:
|
||||
template <typename,std::size_t> friend class multi_array_impl_base;
|
||||
#else
|
||||
public: // should be private
|
||||
#endif
|
||||
|
||||
// constructor used by multi_array_impl_base::generate_array_view to
|
||||
// generate array views
|
||||
template <typename ExtentList, typename Index>
|
||||
explicit multi_array_view(T* base,
|
||||
const ExtentList& extents,
|
||||
const boost::array<Index,NumDims>& strides) :
|
||||
super_type(base,extents,strides) { }
|
||||
|
||||
};
|
||||
|
||||
} // namespace multi_array
|
||||
} // namespace detail
|
||||
|
||||
//
|
||||
// traits classes to get array_view types
|
||||
//
|
||||
template <typename Array, int N>
|
||||
class array_view_gen {
|
||||
typedef typename Array::element element;
|
||||
public:
|
||||
typedef boost::detail::multi_array::multi_array_view<element,N> type;
|
||||
};
|
||||
|
||||
template <typename Array, int N>
|
||||
class const_array_view_gen {
|
||||
typedef typename Array::element element;
|
||||
public:
|
||||
typedef boost::detail::multi_array::const_multi_array_view<element,N> type;
|
||||
};
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#endif // BOOST_MULTI_ARRAY_VIEW_RG071301_HPP
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
Type 1 Prefixes and Suffixes:
|
||||
|
||||
1A 1S 3A 3B6 3B8 3B9 3C 3C0 3D2 3D2C 3D2R 3DA 3V 3W 3X
|
||||
3Y 3YB 3YP 4J 4L 4S 4U1I 4U1U 4W 4X 5A 5B 5H 5N 5R
|
||||
5T 5U 5V 5W 5X 5Z 6W 6Y 7O 7P 7Q 7X 8P 8Q 8R
|
||||
9A 9G 9H 9J 9K 9L 9M2 9M6 9N 9Q 9U 9V 9X 9Y A2
|
||||
A3 A4 A5 A6 A7 A9 AP BS7 BV BV9 BY C2 C3 C5 C6
|
||||
C9 CE CE0X CE0Y CE0Z CE9 CM CN CP CT CT3 CU CX CY0 CY9
|
||||
D2 D4 D6 DL DU E3 E4 EA EA6 EA8 EA9 EI EK EL EP
|
||||
ER ES ET EU EX EY EZ F FG FH FJ FK FKC FM FO
|
||||
FOA FOC FOM FP FR FRG FRJ FRT FT5W FT5X FT5Z FW FY M MD
|
||||
MI MJ MM MU MW H4 H40 HA HB HB0 HC HC8 HH HI HK
|
||||
HK0A HK0M HL HM HP HR HS HV HZ I IS IS0 J2 J3 J5
|
||||
J6 J7 J8 JA JDM JDO JT JW JX JY K KG4 KH0 KH1 KH2
|
||||
KH3 KH4 KH5 KH5K KH6 KH7 KH8 KH9 KL KP1 KP2 KP4 KP5 LA LU
|
||||
LX LY LZ OA OD OE OH OH0 OJ0 OK OM ON OX OY OZ
|
||||
P2 P4 PA PJ2 PJ7 PY PY0F PT0S PY0T PZ R1F R1M S0 S2 S5
|
||||
S7 S9 SM SP ST SU SV SVA SV5 SV9 T2 T30 T31 T32 T33
|
||||
T5 T7 T8 T9 TA TF TG TI TI9 TJ TK TL TN TR TT
|
||||
TU TY TZ UA UA2 UA9 UK UN UR V2 V3 V4 V5 V6 V7
|
||||
V8 VE VK VK0H VK0M VK9C VK9L VK9M VK9N VK9W VK9X VP2E VP2M VP2V VP5
|
||||
VP6 VP6D VP8 VP8G VP8H VP8O VP8S VP9 VQ9 VR VU VU4 VU7 XE XF4
|
||||
XT XU XW XX9 XZ YA YB YI YJ YK YL YN YO YS YU
|
||||
YV YV0 Z2 Z3 ZA ZB ZC4 ZD7 ZD8 ZD9 ZF ZK1N ZK1S ZK2 ZK3
|
||||
ZL ZL7 ZL8 ZL9 ZP ZS ZS8 KC4 E5
|
||||
|
||||
Short-list of Add-on Suffixes: /0 /1 /2 /3 /4 /5 /6 /7 /8 /9 /A /P
|
||||
@@ -0,0 +1,174 @@
|
||||
#ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED
|
||||
#define BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED
|
||||
|
||||
// MS compatible compilers support #pragma once
|
||||
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
//
|
||||
// detail/sp_counted_base_gcc_x86.hpp - g++ on 486+ or AMD64
|
||||
//
|
||||
// Copyright (c) 2001, 2002, 2003 Peter Dimov and Multi Media Ltd.
|
||||
// Copyright 2004-2005 Peter Dimov
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
//
|
||||
// Lock-free algorithm by Alexander Terekhov
|
||||
//
|
||||
// Thanks to Ben Hitchings for the #weak + (#shared != 0)
|
||||
// formulation
|
||||
//
|
||||
|
||||
#include <boost/detail/sp_typeinfo.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
|
||||
namespace detail
|
||||
{
|
||||
|
||||
inline int atomic_exchange_and_add( int * pw, int dv )
|
||||
{
|
||||
// int r = *pw;
|
||||
// *pw += dv;
|
||||
// return r;
|
||||
|
||||
int r;
|
||||
|
||||
__asm__ __volatile__
|
||||
(
|
||||
"lock\n\t"
|
||||
"xadd %1, %0":
|
||||
"=m"( *pw ), "=r"( r ): // outputs (%0, %1)
|
||||
"m"( *pw ), "1"( dv ): // inputs (%2, %3 == %1)
|
||||
"memory", "cc" // clobbers
|
||||
);
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
inline void atomic_increment( int * pw )
|
||||
{
|
||||
//atomic_exchange_and_add( pw, 1 );
|
||||
|
||||
__asm__
|
||||
(
|
||||
"lock\n\t"
|
||||
"incl %0":
|
||||
"=m"( *pw ): // output (%0)
|
||||
"m"( *pw ): // input (%1)
|
||||
"cc" // clobbers
|
||||
);
|
||||
}
|
||||
|
||||
inline int atomic_conditional_increment( int * pw )
|
||||
{
|
||||
// int rv = *pw;
|
||||
// if( rv != 0 ) ++*pw;
|
||||
// return rv;
|
||||
|
||||
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 ): // outputs (%0, %1, %2)
|
||||
"m"( *pw ): // input (%3)
|
||||
"cc" // clobbers
|
||||
);
|
||||
|
||||
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_; // #shared
|
||||
int weak_count_; // #weak + (#shared != 0)
|
||||
|
||||
public:
|
||||
|
||||
sp_counted_base(): use_count_( 1 ), weak_count_( 1 )
|
||||
{
|
||||
}
|
||||
|
||||
virtual ~sp_counted_base() // nothrow
|
||||
{
|
||||
}
|
||||
|
||||
// dispose() is called when use_count_ drops to zero, to release
|
||||
// the resources managed by *this.
|
||||
|
||||
virtual void dispose() = 0; // nothrow
|
||||
|
||||
// destroy() is called when weak_count_ drops to zero.
|
||||
|
||||
virtual void destroy() // nothrow
|
||||
{
|
||||
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() // true on success
|
||||
{
|
||||
return atomic_conditional_increment( &use_count_ ) != 0;
|
||||
}
|
||||
|
||||
void release() // nothrow
|
||||
{
|
||||
if( atomic_exchange_and_add( &use_count_, -1 ) == 1 )
|
||||
{
|
||||
dispose();
|
||||
weak_release();
|
||||
}
|
||||
}
|
||||
|
||||
void weak_add_ref() // nothrow
|
||||
{
|
||||
atomic_increment( &weak_count_ );
|
||||
}
|
||||
|
||||
void weak_release() // nothrow
|
||||
{
|
||||
if( atomic_exchange_and_add( &weak_count_, -1 ) == 1 )
|
||||
{
|
||||
destroy();
|
||||
}
|
||||
}
|
||||
|
||||
long use_count() const // nothrow
|
||||
{
|
||||
return static_cast<int const volatile &>( use_count_ );
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace detail
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#endif // #ifndef BOOST_SMART_PTR_DETAIL_SP_COUNTED_BASE_GCC_X86_HPP_INCLUDED
|
||||
@@ -0,0 +1,124 @@
|
||||
//---------------------------------------------------------------------------//
|
||||
// Copyright (c) 2013 Kyle Lutz <kyle.r.lutz@gmail.com>
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0
|
||||
// See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt
|
||||
//
|
||||
// See http://boostorg.github.com/compute for more information.
|
||||
//---------------------------------------------------------------------------//
|
||||
|
||||
#ifndef BOOST_COMPUTE_TYPE_TRAITS_TYPE_NAME_HPP
|
||||
#define BOOST_COMPUTE_TYPE_TRAITS_TYPE_NAME_HPP
|
||||
|
||||
#include <boost/preprocessor/cat.hpp>
|
||||
#include <boost/preprocessor/stringize.hpp>
|
||||
|
||||
#include <boost/compute/types/fundamental.hpp>
|
||||
|
||||
namespace boost {
|
||||
namespace compute {
|
||||
namespace detail {
|
||||
|
||||
template<class T>
|
||||
struct type_name_trait;
|
||||
|
||||
/// \internal_
|
||||
#define BOOST_COMPUTE_DEFINE_SCALAR_TYPE_NAME_FUNCTION(type) \
|
||||
template<> \
|
||||
struct type_name_trait<BOOST_PP_CAT(type, _)> \
|
||||
{ \
|
||||
static const char* value() \
|
||||
{ \
|
||||
return BOOST_PP_STRINGIZE(type); \
|
||||
} \
|
||||
};
|
||||
|
||||
/// \internal_
|
||||
#define BOOST_COMPUTE_DEFINE_VECTOR_TYPE_NAME_FUNCTION(scalar, n) \
|
||||
template<> \
|
||||
struct type_name_trait<BOOST_PP_CAT(BOOST_PP_CAT(scalar, n), _)> \
|
||||
{ \
|
||||
static const char* value() \
|
||||
{ \
|
||||
return BOOST_PP_STRINGIZE(BOOST_PP_CAT(scalar, n)); \
|
||||
} \
|
||||
};
|
||||
|
||||
/// \internal_
|
||||
#define BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(scalar) \
|
||||
BOOST_COMPUTE_DEFINE_SCALAR_TYPE_NAME_FUNCTION(scalar) \
|
||||
BOOST_COMPUTE_DEFINE_VECTOR_TYPE_NAME_FUNCTION(scalar, 2) \
|
||||
BOOST_COMPUTE_DEFINE_VECTOR_TYPE_NAME_FUNCTION(scalar, 4) \
|
||||
BOOST_COMPUTE_DEFINE_VECTOR_TYPE_NAME_FUNCTION(scalar, 8) \
|
||||
BOOST_COMPUTE_DEFINE_VECTOR_TYPE_NAME_FUNCTION(scalar, 16)
|
||||
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(char)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(uchar)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(short)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(ushort)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(int)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(uint)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(long)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(ulong)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(float)
|
||||
BOOST_COMPUTE_DEFINE_TYPE_NAME_FUNCTIONS(double)
|
||||
|
||||
/// \internal_
|
||||
#define BOOST_COMPUTE_DEFINE_BUILTIN_TYPE_NAME_FUNCTION(type) \
|
||||
template<> \
|
||||
struct type_name_trait<type> \
|
||||
{ \
|
||||
static const char* value() \
|
||||
{ \
|
||||
return #type; \
|
||||
} \
|
||||
};
|
||||
|
||||
BOOST_COMPUTE_DEFINE_BUILTIN_TYPE_NAME_FUNCTION(bool)
|
||||
BOOST_COMPUTE_DEFINE_BUILTIN_TYPE_NAME_FUNCTION(char)
|
||||
BOOST_COMPUTE_DEFINE_BUILTIN_TYPE_NAME_FUNCTION(void)
|
||||
|
||||
} // end detail namespace
|
||||
|
||||
/// Returns the OpenCL type name for the type \c T as a string.
|
||||
///
|
||||
/// \return a string containing the type name for \c T
|
||||
///
|
||||
/// For example:
|
||||
/// \code
|
||||
/// type_name<float>() == "float"
|
||||
/// type_name<float4_>() == "float4"
|
||||
/// \endcode
|
||||
///
|
||||
/// \see type_definition<T>()
|
||||
template<class T>
|
||||
inline const char* type_name()
|
||||
{
|
||||
return detail::type_name_trait<T>::value();
|
||||
}
|
||||
|
||||
} // end compute namespace
|
||||
} // end boost namespace
|
||||
|
||||
/// Registers the OpenCL type for the C++ \p type to \p name.
|
||||
///
|
||||
/// For example, the following will allow Eigen's \c Vector2f type
|
||||
/// to be used with Boost.Compute algorithms and containers as the
|
||||
/// built-in \c float2 type.
|
||||
/// \code
|
||||
/// BOOST_COMPUTE_TYPE_NAME(Eigen::Vector2f, float2)
|
||||
/// \endcode
|
||||
///
|
||||
/// This macro should be invoked in the global namespace.
|
||||
///
|
||||
/// \see type_name()
|
||||
#define BOOST_COMPUTE_TYPE_NAME(type, name) \
|
||||
namespace boost { namespace compute { \
|
||||
template<> \
|
||||
inline const char* type_name<type>() \
|
||||
{ \
|
||||
return #name; \
|
||||
}}}
|
||||
|
||||
#endif // BOOST_COMPUTE_TYPE_TRAITS_TYPE_NAME_HPP
|
||||
@@ -0,0 +1,50 @@
|
||||
subroutine encode174(message,codeword)
|
||||
! Encode an 101-bit message and return a 174-bit codeword.
|
||||
! The generator matrix has dimensions (73,101).
|
||||
! The code is a (174,101) regular ldpc code with column weight 3.
|
||||
! The code was generated using the PEG algorithm.
|
||||
! After creating the codeword, the columns are re-ordered according to
|
||||
! "colorder" to make the codeword compatible with the parity-check matrix
|
||||
!
|
||||
|
||||
include "ldpc_174_87_params.f90"
|
||||
|
||||
integer*1 codeword(N)
|
||||
integer*1 gen(M,K)
|
||||
integer*1 itmp(N)
|
||||
integer*1 message(K)
|
||||
integer*1 pchecks(M)
|
||||
logical first
|
||||
data first/.true./
|
||||
|
||||
save first,gen
|
||||
|
||||
if( first ) then ! fill the generator matrix
|
||||
gen=0
|
||||
do i=1,M
|
||||
do j=1,11
|
||||
read(g(i)( (j-1)*2+1:(j-1)*2+2 ),"(Z2)") istr
|
||||
do jj=1, 8
|
||||
icol=(j-1)*8+jj
|
||||
if( icol .le. 87 ) then
|
||||
if( btest(istr,8-jj) ) gen(i,icol)=1
|
||||
endif
|
||||
enddo
|
||||
enddo
|
||||
enddo
|
||||
first=.false.
|
||||
endif
|
||||
|
||||
do i=1,M
|
||||
nsum=0
|
||||
do j=1,K
|
||||
nsum=nsum+message(j)*gen(i,j)
|
||||
enddo
|
||||
pchecks(i)=mod(nsum,2)
|
||||
enddo
|
||||
itmp(1:M)=pchecks
|
||||
itmp(M+1:N)=message(1:K)
|
||||
codeword(colorder+1)=itmp(1:N)
|
||||
|
||||
return
|
||||
end subroutine encode174
|
||||
@@ -0,0 +1,57 @@
|
||||
#ifndef GREG_DAY_HPP___
|
||||
#define GREG_DAY_HPP___
|
||||
|
||||
/* Copyright (c) 2002,2003 CrystalClear Software, Inc.
|
||||
* Use, modification and distribution is subject to the
|
||||
* Boost Software License, Version 1.0. (See accompanying
|
||||
* file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
|
||||
* Author: Jeff Garland
|
||||
* $Date$
|
||||
*/
|
||||
|
||||
#include "boost/date_time/constrained_value.hpp"
|
||||
#include <stdexcept>
|
||||
#include <string>
|
||||
|
||||
namespace boost {
|
||||
namespace gregorian {
|
||||
|
||||
//! Exception type for gregorian day of month (1..31)
|
||||
struct bad_day_of_month : public std::out_of_range
|
||||
{
|
||||
bad_day_of_month() :
|
||||
std::out_of_range(std::string("Day of month value is out of range 1..31"))
|
||||
{}
|
||||
//! Allow other classes to throw with unique string for bad day like Feb 29
|
||||
bad_day_of_month(const std::string& s) :
|
||||
std::out_of_range(s)
|
||||
{}
|
||||
};
|
||||
//! Policy class that declares error handling and day of month ranges
|
||||
typedef CV::simple_exception_policy<unsigned short, 1, 31, bad_day_of_month> greg_day_policies;
|
||||
|
||||
//! Generated represetation for gregorian day of month
|
||||
typedef CV::constrained_value<greg_day_policies> greg_day_rep;
|
||||
|
||||
//! Represent a day of the month (range 1 - 31)
|
||||
/*! This small class allows for simple conversion an integer value into
|
||||
a day of the month for a standard gregorian calendar. The type
|
||||
is automatically range checked so values outside of the range 1-31
|
||||
will cause a bad_day_of_month exception
|
||||
*/
|
||||
class greg_day : public greg_day_rep {
|
||||
public:
|
||||
greg_day(unsigned short day_of_month) : greg_day_rep(day_of_month) {}
|
||||
unsigned short as_number() const {return value_;}
|
||||
operator unsigned short() const {return value_;}
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
} } //namespace gregorian
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,45 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// (C) Copyright Ion Gaztanaga 2006-2013
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef BOOST_INTRUSIVE_DETAIL_ASSERT_HPP
|
||||
#define BOOST_INTRUSIVE_DETAIL_ASSERT_HPP
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_PRAGMA_ONCE)
|
||||
#pragma once
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_INTRUSIVE_INVARIANT_ASSERT)
|
||||
#include <boost/assert.hpp>
|
||||
#define BOOST_INTRUSIVE_INVARIANT_ASSERT BOOST_ASSERT
|
||||
#elif defined(BOOST_INTRUSIVE_INVARIANT_ASSERT_INCLUDE)
|
||||
#include BOOST_INTRUSIVE_INVARIANT_ASSERT_INCLUDE
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT)
|
||||
#include <boost/assert.hpp>
|
||||
#define BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT BOOST_ASSERT
|
||||
#elif defined(BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT_INCLUDE)
|
||||
#include BOOST_INTRUSIVE_SAFE_HOOK_DEFAULT_ASSERT_INCLUDE
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT)
|
||||
#include <boost/assert.hpp>
|
||||
#define BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT BOOST_ASSERT
|
||||
#elif defined(BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT_INCLUDE)
|
||||
#include BOOST_INTRUSIVE_SAFE_HOOK_DESTRUCTOR_ASSERT_INCLUDE
|
||||
#endif
|
||||
|
||||
#endif //BOOST_INTRUSIVE_DETAIL_ASSERT_HPP
|
||||
@@ -0,0 +1,35 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// (C) Copyright Ion Gaztanaga 2014-2014
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef BOOST_INTRUSIVE_DETAIL_NODE_HOLDER_HPP
|
||||
#define BOOST_INTRUSIVE_DETAIL_NODE_HOLDER_HPP
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_PRAGMA_ONCE)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
namespace boost {
|
||||
namespace intrusive {
|
||||
|
||||
template<class Node, class Tag, unsigned int>
|
||||
struct node_holder
|
||||
: public Node
|
||||
{};
|
||||
|
||||
} //namespace intrusive{
|
||||
} //namespace boost{
|
||||
|
||||
#endif //BOOST_INTRUSIVE_DETAIL_NODE_HOLDER_HPP
|
||||
@@ -0,0 +1,242 @@
|
||||
set (LANGUAGES
|
||||
en
|
||||
)
|
||||
|
||||
set (common_SRCS
|
||||
common/communication.adoc
|
||||
common/license.adoc
|
||||
common/links.adoc
|
||||
)
|
||||
|
||||
set (UG_SRCS
|
||||
docinfo.html
|
||||
docinfo.xml
|
||||
acknowledgements.adoc
|
||||
astro_data.adoc
|
||||
config-details.adoc
|
||||
controls-functions-center.adoc
|
||||
controls-functions-left.adoc
|
||||
controls-functions-main-window.adoc
|
||||
controls-functions-menus.adoc
|
||||
controls-functions-messages.adoc
|
||||
controls-functions-status-bar.adoc
|
||||
controls-functions-wide-graph.adoc
|
||||
cooperating-programs.adoc
|
||||
decoder_notes.adoc
|
||||
faq.adoc
|
||||
font-sizes.adoc
|
||||
install-from-source.adoc
|
||||
install-linux.adoc
|
||||
install-mac.adoc
|
||||
install-windows.adoc
|
||||
introduction.adoc
|
||||
measurement_tools.adoc
|
||||
protocols.adoc
|
||||
logging.adoc
|
||||
make-qso.adoc
|
||||
measurement_tools.adoc
|
||||
new_features.adoc
|
||||
platform-dependencies.adoc
|
||||
protocols.adoc
|
||||
settings-advanced.adoc
|
||||
settings-audio.adoc
|
||||
settings-colors.adoc
|
||||
settings-frequencies.adoc
|
||||
settings-general.adoc
|
||||
settings-radio.adoc
|
||||
settings-reporting.adoc
|
||||
settings-txmacros.adoc
|
||||
support.adoc
|
||||
system-requirements.adoc
|
||||
transceiver-setup.adoc
|
||||
tutorial-example1.adoc
|
||||
tutorial-example2.adoc
|
||||
tutorial-example3.adoc
|
||||
tutorial-main-window.adoc
|
||||
tutorial-wide-graph-settings.adoc
|
||||
utilities.adoc
|
||||
vhf-features.adoc
|
||||
wsjtx-main.adoc
|
||||
wspr.adoc
|
||||
)
|
||||
|
||||
set (UG_IMGS
|
||||
images/130610_2343-wav-80.png
|
||||
images/170709_135615.wav.png
|
||||
images/AstroData_2.png
|
||||
images/Astronomical_data.png
|
||||
images/auto-seq.png
|
||||
images/band-settings.png
|
||||
images/colors.png
|
||||
images/config-menu.png
|
||||
images/decode-menu.png
|
||||
images/decodes.png
|
||||
images/download_samples.png
|
||||
images/file-menu.png
|
||||
images/FreqCal.png
|
||||
images/FreqCal_Graph.png
|
||||
images/FreqCal_Results.png
|
||||
images/freemsg.png
|
||||
images/ft8_decodes.png
|
||||
images/help-menu.png
|
||||
images/JT4F.png
|
||||
images/JT65B.png
|
||||
images/keyboard-shortcuts.png
|
||||
images/MSK144.png
|
||||
images/QRA64.png
|
||||
images/WSPR_WideGraphControls.png
|
||||
images/WSPR_1a.png
|
||||
images/WSPR_2.png
|
||||
images/jtalert.png
|
||||
images/keyboard-shortcuts.png
|
||||
images/log-qso.png
|
||||
images/MacAppMenu.png
|
||||
images/main-ui.png
|
||||
images/main-ui-controls.png
|
||||
images/misc-controls-center.png
|
||||
images/misc-main-ui.png
|
||||
images/mode-menu.png
|
||||
images/new-msg-box.png
|
||||
images/psk-reporter.png
|
||||
images/r3666-config-screen-80.png
|
||||
images/r3666-main-ui-80.png
|
||||
images/r4148-txmac-ui.png
|
||||
images/RadioTab.png
|
||||
images/reporting.png
|
||||
images/save-menu.png
|
||||
images/settings-advanced.png
|
||||
images/settings-audio.png
|
||||
images/settings-frequencies.png
|
||||
images/settings-general.png
|
||||
images/setup-menu.png
|
||||
images/special-mouse-commands.png
|
||||
images/status-bar-a.png
|
||||
images/tools-menu.png
|
||||
images/traditional-msg-box.png
|
||||
images/tx-macros.png
|
||||
images/VHF_controls.png
|
||||
images/view-menu.png
|
||||
images/wide-graph-controls.png
|
||||
|
||||
)
|
||||
|
||||
find_program (ASCIIDOCTOR_EXECUTABLE NAMES asciidoctor)
|
||||
if (NOT ASCIIDOCTOR_EXECUTABLE)
|
||||
message (FATAL_ERROR "asciidoctor is required to build the documentation
|
||||
|
||||
Building the documenation may optionally be turned off by setting the CMake
|
||||
option WSJT_GENERATE_DOCS to OFF.")
|
||||
endif (NOT ASCIIDOCTOR_EXECUTABLE)
|
||||
|
||||
find_program (FOPUB_EXECUTABLE NAMES fopub)
|
||||
|
||||
include (CMakeParseArguments)
|
||||
|
||||
# generate a document from asciidoc text files(s)
|
||||
#
|
||||
# HTML - generate an HTML document
|
||||
# PDF - generate a PDF document
|
||||
# SOURCE - top level asciidoc file
|
||||
# ASCIIDOCTOR_OPTIONS - asciidoctor command options
|
||||
# DEPENDS - dependent files
|
||||
function (document)
|
||||
cmake_parse_arguments (_args "HTML" "SOURCE;LANG;OUTPUT" "ASCIIDOCTOR_OPTIONS;PDF;DEPENDS" ${ARGN})
|
||||
get_filename_component (_source_path ${_args_SOURCE} PATH)
|
||||
get_filename_component (_source_name ${_args_SOURCE} NAME)
|
||||
get_filename_component (_output_name_we ${_args_SOURCE} NAME_WE)
|
||||
|
||||
# HTML
|
||||
if (${_args_HTML})
|
||||
set (_html_file ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang}.html)
|
||||
add_custom_command (
|
||||
OUTPUT ${_html_file}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${_source_path}/${lang}
|
||||
COMMAND ${ASCIIDOCTOR_EXECUTABLE} ${_args_ASCIIDOCTOR_OPTIONS}
|
||||
-b html5
|
||||
-a VERSION_MAJOR=${WSJTX_VERSION_MAJOR}
|
||||
-a VERSION_MINOR=${WSJTX_VERSION_MINOR}
|
||||
-a VERSION_PATCH=${WSJTX_VERSION_PATCH}
|
||||
-a VERSION=${wsjtx_VERSION}
|
||||
--out-file=${_html_file} ${_source_name}
|
||||
DEPENDS ${_args_DEPENDS}
|
||||
COMMENT "Generating ${_html_file}"
|
||||
)
|
||||
list (APPEND _output_files ${_html_file})
|
||||
endif (${_args_HTML})
|
||||
|
||||
# PDF
|
||||
if (_args_PDF AND EXISTS ${FOPUB_EXECUTABLE})
|
||||
set (_docbook_file ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang}.xml)
|
||||
set (_pdf_file_we ${CMAKE_CURRENT_BINARY_DIR}/${_output_name_we}_${lang})
|
||||
if (${lang} MATCHES "^(en|es|fr)$") # en-us, fr-ca and es-{mx,co} use US-Letter or equivalent
|
||||
set (_usl_commands
|
||||
COMMAND ${FOPUB_EXECUTABLE} ARGS ${_docbook_file} ${_args_PDF} -param paper.type USLetter
|
||||
COMMAND ${CMAKE_COMMAND} ARGS -E rename ${_pdf_file_we}.pdf '${_pdf_file_we} \(USLetter\).pdf'
|
||||
)
|
||||
list (APPEND _output_files "${_pdf_file_we} (USLetter).pdf")
|
||||
endif ()
|
||||
list (APPEND _output_files "${_pdf_file_we}.pdf")
|
||||
add_custom_command (
|
||||
OUTPUT ${_docbook_file} ${_output_files}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${_source_path}/${lang}
|
||||
COMMAND ${ASCIIDOCTOR_EXECUTABLE} ARGS ${_args_ASCIIDOCTOR_OPTIONS}
|
||||
-b docbook
|
||||
-a data-uri!
|
||||
-a VERSION_MAJOR=${WSJTX_VERSION_MAJOR}
|
||||
-a VERSION_MINOR=${WSJTX_VERSION_MINOR}
|
||||
-a VERSION_PATCH=${WSJTX_VERSION_PATCH}
|
||||
-a VERSION=${wsjtx_VERSION}
|
||||
-D ${CMAKE_CURRENT_BINARY_DIR}
|
||||
-o ${_docbook_file} ${_source_name}
|
||||
${_usl_commands}
|
||||
COMMAND ${FOPUB_EXECUTABLE} ARGS ${_docbook_file} ${_args_PDF} -param paper.type A4
|
||||
COMMAND ${CMAKE_COMMAND} ARGS -E rename ${_pdf_file_we}.pdf '${_pdf_file_we}.pdf'
|
||||
DEPENDS ${_args_DEPENDS}
|
||||
COMMENT "Generating ${_output_files}"
|
||||
)
|
||||
endif (_args_PDF AND EXISTS ${FOPUB_EXECUTABLE})
|
||||
|
||||
set (${_args_OUTPUT} ${_output_files} PARENT_SCOPE)
|
||||
endfunction (document)
|
||||
|
||||
set (htmls)
|
||||
set (pdfs)
|
||||
foreach (lang ${LANGUAGES})
|
||||
set (_sources)
|
||||
foreach (_src ${UG_SRCS} ${UG_IMGS})
|
||||
list (APPEND _sources "user_guide/${lang}/${_src}")
|
||||
endforeach ()
|
||||
document(
|
||||
HTML
|
||||
SOURCE user_guide/wsjtx-main.adoc
|
||||
LANG "${lang}"
|
||||
OUTPUT html
|
||||
ASCIIDOCTOR_OPTIONS -d book -a data-uri -a toc=left -a max-width=1024px
|
||||
DEPENDS ${common_SRCS} ${_sources}
|
||||
)
|
||||
document(
|
||||
PDF -param body.font.master 11 -param body.font.family "'Noto Sans, Helvetica, sans-serif'" -param title.font.family "'Noto Serif, Times New Roman, serif'" -param page.margin.inner 1cm -param page.margin.outer 1cm -param page.margin.top 0.75cm -param page.margin.bottom 0.5cm -param generate.toc 0
|
||||
SOURCE user_guide/wsjtx-main.adoc
|
||||
LANG "${lang}"
|
||||
OUTPUT pdf
|
||||
ASCIIDOCTOR_OPTIONS -d book
|
||||
DEPENDS ${common_SRCS} ${_sources}
|
||||
)
|
||||
list (APPEND htmls "${html}")
|
||||
list (APPEND pdfs "${pdf}")
|
||||
endforeach ()
|
||||
|
||||
add_custom_target (docs ALL DEPENDS ${htmls} ${pdfs})
|
||||
|
||||
foreach (_html ${htmls})
|
||||
get_filename_component (_path ${_html} PATH)
|
||||
get_filename_component (_nwe ${_html} NAME_WE)
|
||||
get_filename_component (_ext ${_html} EXT)
|
||||
string (REGEX REPLACE "_en$" "" _nwe ${_nwe})
|
||||
install (FILES
|
||||
${_html}
|
||||
DESTINATION ${CMAKE_INSTALL_DOCDIR}
|
||||
RENAME ${_nwe}-${wsjtx_VERSION}${_ext}
|
||||
#COMPONENT runtime
|
||||
)
|
||||
endforeach ()
|
||||
@@ -0,0 +1,69 @@
|
||||
// Boost string_algo library slist_traits.hpp header file ---------------------------//
|
||||
|
||||
// Copyright Pavol Droba 2002-2003.
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0.
|
||||
// (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/ for updates, documentation, and revision history.
|
||||
|
||||
#ifndef BOOST_STRING_STD_SLIST_TRAITS_HPP
|
||||
#define BOOST_STRING_STD_SLIST_TRAITS_HPP
|
||||
|
||||
#include <boost/algorithm/string/config.hpp>
|
||||
#include <boost/algorithm/string/yes_no_type.hpp>
|
||||
#include BOOST_SLIST_HEADER
|
||||
#include <boost/algorithm/string/sequence_traits.hpp>
|
||||
|
||||
namespace boost {
|
||||
namespace algorithm {
|
||||
|
||||
// SGI's std::slist<> traits -----------------------------------------------//
|
||||
|
||||
|
||||
// stable iterators trait
|
||||
template<typename T, typename AllocT>
|
||||
class has_stable_iterators< BOOST_STD_EXTENSION_NAMESPACE::slist<T,AllocT> >
|
||||
{
|
||||
public:
|
||||
#if BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
enum { value = true };
|
||||
#else
|
||||
BOOST_STATIC_CONSTANT(bool, value=true);
|
||||
#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
typedef mpl::bool_<has_stable_iterators<T>::value> type;
|
||||
};
|
||||
|
||||
// const time insert trait
|
||||
template<typename T, typename AllocT>
|
||||
class has_const_time_insert< BOOST_STD_EXTENSION_NAMESPACE::slist<T,AllocT> >
|
||||
{
|
||||
public:
|
||||
#if BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
enum { value = true };
|
||||
#else
|
||||
BOOST_STATIC_CONSTANT(bool, value=true);
|
||||
#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
typedef mpl::bool_<has_const_time_insert<T>::value> type;
|
||||
};
|
||||
|
||||
// const time erase trait
|
||||
template<typename T, typename AllocT>
|
||||
class has_const_time_erase< BOOST_STD_EXTENSION_NAMESPACE::slist<T,AllocT> >
|
||||
{
|
||||
public:
|
||||
#if BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
enum { value = true };
|
||||
#else
|
||||
BOOST_STATIC_CONSTANT(bool, value=true);
|
||||
#endif // BOOST_WORKAROUND( __IBMCPP__, <= 600 )
|
||||
typedef mpl::bool_<has_const_time_erase<T>::value> type;
|
||||
};
|
||||
|
||||
|
||||
} // namespace algorithm
|
||||
} // namespace boost
|
||||
|
||||
|
||||
#endif // BOOST_STRING_STD_LIST_TRAITS_HPP
|
||||
@@ -0,0 +1,48 @@
|
||||
// Copyright David Abrahams 2002.
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
#ifndef EXCEPTION_HANDLER_DWA2002810_HPP
|
||||
# define EXCEPTION_HANDLER_DWA2002810_HPP
|
||||
|
||||
# include <boost/python/detail/config.hpp>
|
||||
# include <boost/function/function0.hpp>
|
||||
# include <boost/function/function2.hpp>
|
||||
|
||||
namespace boost { namespace python { namespace detail {
|
||||
|
||||
struct BOOST_PYTHON_DECL_FORWARD exception_handler;
|
||||
|
||||
typedef function2<bool, exception_handler const&, function0<void> const&> handler_function;
|
||||
|
||||
struct BOOST_PYTHON_DECL exception_handler
|
||||
{
|
||||
private: // types
|
||||
|
||||
public:
|
||||
explicit exception_handler(handler_function const& impl);
|
||||
|
||||
inline bool handle(function0<void> const& f) const;
|
||||
|
||||
bool operator()(function0<void> const& f) const;
|
||||
|
||||
static exception_handler* chain;
|
||||
|
||||
private:
|
||||
static exception_handler* tail;
|
||||
|
||||
handler_function m_impl;
|
||||
exception_handler* m_next;
|
||||
};
|
||||
|
||||
|
||||
inline bool exception_handler::handle(function0<void> const& f) const
|
||||
{
|
||||
return this->m_impl(*this, f);
|
||||
}
|
||||
|
||||
BOOST_PYTHON_DECL void register_exception_handler(handler_function const& f);
|
||||
|
||||
}}} // namespace boost::python::detail
|
||||
|
||||
#endif // EXCEPTION_HANDLER_DWA2002810_HPP
|
||||
Reference in New Issue
Block a user