Initial Commit
This commit is contained in:
@@ -0,0 +1,86 @@
|
||||
/*=============================================================================
|
||||
Copyright (c) 1999-2003 Jaakko Jarvi
|
||||
Copyright (c) 1999-2003 Jeremiah Willcock
|
||||
Copyright (c) 2001-2011 Joel de Guzman
|
||||
|
||||
Distributed under the Boost Software License, Version 1.0. (See accompanying
|
||||
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
==============================================================================*/
|
||||
#if !defined(FUSION_IN_05052005_0121)
|
||||
#define FUSION_IN_05052005_0121
|
||||
|
||||
#include <boost/fusion/support/config.hpp>
|
||||
#include <istream>
|
||||
#include <boost/fusion/sequence/io/detail/manip.hpp>
|
||||
|
||||
#include <boost/mpl/bool.hpp>
|
||||
#include <boost/fusion/sequence/intrinsic/begin.hpp>
|
||||
#include <boost/fusion/sequence/intrinsic/end.hpp>
|
||||
#include <boost/fusion/iterator/deref.hpp>
|
||||
#include <boost/fusion/iterator/next.hpp>
|
||||
#include <boost/fusion/iterator/equal_to.hpp>
|
||||
|
||||
namespace boost { namespace fusion { namespace detail
|
||||
{
|
||||
template <typename Tag>
|
||||
struct delimiter_in
|
||||
{
|
||||
// read a delimiter
|
||||
template <typename IS>
|
||||
static void
|
||||
read(IS& is, char const* delim, mpl::false_ = mpl::false_())
|
||||
{
|
||||
detail::string_ios_manip<Tag, IS> manip(is);
|
||||
manip.read(delim);
|
||||
}
|
||||
|
||||
template <typename IS>
|
||||
static void
|
||||
read(IS&, char const*, mpl::true_)
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
struct read_sequence_loop
|
||||
{
|
||||
template <typename IS, typename First, typename Last>
|
||||
static void
|
||||
call(IS&, First const&, Last const&, mpl::true_)
|
||||
{
|
||||
}
|
||||
|
||||
template <typename IS, typename First, typename Last>
|
||||
static void
|
||||
call(IS& is, First const& first, Last const& last, mpl::false_)
|
||||
{
|
||||
result_of::equal_to<
|
||||
typename result_of::next<First>::type
|
||||
, Last
|
||||
>
|
||||
is_last;
|
||||
|
||||
is >> *first;
|
||||
delimiter_in<tuple_delimiter_tag>::read(is, " ", is_last);
|
||||
call(is, fusion::next(first), last, is_last);
|
||||
}
|
||||
|
||||
template <typename IS, typename First, typename Last>
|
||||
static void
|
||||
call(IS& is, First const& first, Last const& last)
|
||||
{
|
||||
result_of::equal_to<First, Last> eq;
|
||||
call(is, first, last, eq);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename IS, typename Sequence>
|
||||
inline void
|
||||
read_sequence(IS& is, Sequence& seq)
|
||||
{
|
||||
delimiter_in<tuple_open_tag>::read(is, "(");
|
||||
read_sequence_loop::call(is, fusion::begin(seq), fusion::end(seq));
|
||||
delimiter_in<tuple_close_tag>::read(is, ")");
|
||||
}
|
||||
}}}
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,10 @@
|
||||
/*
|
||||
Copyright Rene Rivera 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)
|
||||
*/
|
||||
|
||||
#ifndef BOOST_PREDEF_DETAIL_COMP_DETECTED
|
||||
#define BOOST_PREDEF_DETAIL_COMP_DETECTED 1
|
||||
#endif
|
||||
@@ -0,0 +1,214 @@
|
||||
/*
|
||||
* Copyright (c) 2012-2014 Glen Joseph Fernandes
|
||||
* glenfe at live dot com
|
||||
*
|
||||
* Distributed under the Boost Software License,
|
||||
* Version 1.0. (See accompanying file LICENSE_1_0.txt
|
||||
* or copy at http://boost.org/LICENSE_1_0.txt)
|
||||
*/
|
||||
#ifndef BOOST_SMART_PTR_DETAIL_ARRAY_UTILITY_HPP
|
||||
#define BOOST_SMART_PTR_DETAIL_ARRAY_UTILITY_HPP
|
||||
|
||||
#include <boost/config.hpp>
|
||||
#include <boost/type_traits/has_trivial_constructor.hpp>
|
||||
#include <boost/type_traits/has_trivial_destructor.hpp>
|
||||
#if !defined(BOOST_NO_CXX11_ALLOCATOR)
|
||||
#include <memory>
|
||||
#endif
|
||||
|
||||
namespace boost {
|
||||
namespace detail {
|
||||
typedef boost::true_type ms_is_trivial;
|
||||
typedef boost::false_type ms_no_trivial;
|
||||
|
||||
template<class T>
|
||||
inline void ms_destroy(T*, std::size_t, ms_is_trivial) {
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_destroy(T* memory, std::size_t size, ms_no_trivial) {
|
||||
for (std::size_t i = size; i > 0;) {
|
||||
memory[--i].~T();
|
||||
}
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_destroy(T* memory, std::size_t size) {
|
||||
boost::has_trivial_destructor<T> trivial;
|
||||
ms_destroy(memory, size, trivial);
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_init(T* memory, std::size_t size, ms_is_trivial) {
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T();
|
||||
}
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_init(T* memory, std::size_t size, ms_no_trivial) {
|
||||
#if !defined(BOOST_NO_EXCEPTIONS)
|
||||
std::size_t i = 0;
|
||||
try {
|
||||
for (; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T();
|
||||
}
|
||||
} catch (...) {
|
||||
ms_destroy(memory, i);
|
||||
throw;
|
||||
}
|
||||
#else
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_init(T* memory, std::size_t size) {
|
||||
boost::has_trivial_default_constructor<T> trivial;
|
||||
ms_init(memory, size, trivial);
|
||||
}
|
||||
|
||||
template<class T, std::size_t N>
|
||||
inline void ms_init(T* memory, std::size_t size, const T* list) {
|
||||
#if !defined(BOOST_NO_EXCEPTIONS)
|
||||
std::size_t i = 0;
|
||||
try {
|
||||
for (; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T(list[i % N]);
|
||||
}
|
||||
} catch (...) {
|
||||
ms_destroy(memory, i);
|
||||
throw;
|
||||
}
|
||||
#else
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T(list[i % N]);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#if !defined(BOOST_NO_CXX11_ALLOCATOR)
|
||||
template<class T, class A>
|
||||
inline void as_destroy(const A& allocator, T* memory,
|
||||
std::size_t size) {
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_alloc<T> TA;
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_traits<T> TT;
|
||||
TA a2(allocator);
|
||||
for (std::size_t i = size; i > 0;) {
|
||||
TT::destroy(a2, &memory[--i]);
|
||||
}
|
||||
}
|
||||
|
||||
template<class T, class A>
|
||||
inline void as_init(const A& allocator, T* memory, std::size_t size,
|
||||
ms_is_trivial) {
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_alloc<T> TA;
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_traits<T> TT;
|
||||
TA a2(allocator);
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
TT::construct(a2, memory + i);
|
||||
}
|
||||
}
|
||||
|
||||
template<class T, class A>
|
||||
inline void as_init(const A& allocator, T* memory, std::size_t size,
|
||||
ms_no_trivial) {
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_alloc<T> TA;
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_traits<T> TT;
|
||||
TA a2(allocator);
|
||||
#if !defined(BOOST_NO_EXCEPTIONS)
|
||||
std::size_t i = 0;
|
||||
try {
|
||||
for (; i < size; i++) {
|
||||
TT::construct(a2, memory + i);
|
||||
}
|
||||
} catch (...) {
|
||||
as_destroy(a2, memory, i);
|
||||
throw;
|
||||
}
|
||||
#else
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
TT::construct(a2, memory + i);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
template<class T, class A>
|
||||
inline void as_init(const A& allocator, T* memory, std::size_t size) {
|
||||
boost::has_trivial_default_constructor<T> trivial;
|
||||
as_init(allocator, memory, size, trivial);
|
||||
}
|
||||
|
||||
template<class T, class A, std::size_t N>
|
||||
inline void as_init(const A& allocator, T* memory, std::size_t size,
|
||||
const T* list) {
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_alloc<T> TA;
|
||||
typedef typename std::allocator_traits<A>::
|
||||
template rebind_traits<T> TT;
|
||||
TA a2(allocator);
|
||||
#if !defined(BOOST_NO_EXCEPTIONS)
|
||||
std::size_t i = 0;
|
||||
try {
|
||||
for (; i < size; i++) {
|
||||
TT::construct(a2, memory + i, list[i % N]);
|
||||
}
|
||||
} catch (...) {
|
||||
as_destroy(a2, memory, i);
|
||||
throw;
|
||||
}
|
||||
#else
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
TT::construct(a2, memory + i, list[i % N]);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
template<class T>
|
||||
inline void ms_noinit(T*, std::size_t, ms_is_trivial) {
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_noinit(T* memory, std::size_t size, ms_no_trivial) {
|
||||
#if !defined(BOOST_NO_EXCEPTIONS)
|
||||
std::size_t i = 0;
|
||||
try {
|
||||
for (; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T;
|
||||
}
|
||||
} catch (...) {
|
||||
ms_destroy(memory, i);
|
||||
throw;
|
||||
}
|
||||
#else
|
||||
for (std::size_t i = 0; i < size; i++) {
|
||||
void* p1 = memory + i;
|
||||
::new(p1) T;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
template<class T>
|
||||
inline void ms_noinit(T* memory, std::size_t size) {
|
||||
boost::has_trivial_default_constructor<T> trivial;
|
||||
ms_noinit(memory, size, trivial);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,30 @@
|
||||
[Setup]
|
||||
AppName=wsjtx
|
||||
AppVerName=wsjtx Version 1.3 r3673
|
||||
AppCopyright=Copyright (C) 2001-2014 by Joe Taylor, K1JT
|
||||
DefaultDirName=c:\wsjtx_w
|
||||
DefaultGroupName=wsjtx_w
|
||||
|
||||
[Files]
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\wsjtx.exe"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\jt9.exe"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\jt9code.exe"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\kvasd.exe"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\*.dll"; DestDir: "{app}";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\cty.dat"; DestDir: "{app}";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\kvasd.dat"; DestDir: "{app}";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\wsjt.ico"; DestDir: "{app}";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\qt.conf"; DestDir: "{app}";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\CALL3.TXT"; DestDir: "{app}"; Flags: onlyifdoesntexist
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\shortcuts.txt"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\mouse_commands.txt"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx\prefixes.txt"; DestDir: "{app}"
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\save\Samples\130418_1742.wav"; DestDir: "{app}\save\Samples";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\save\Samples\130610_2343.wav"; DestDir: "{app}\save\Samples";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\platforms\qwindows.dll"; DestDir: "{app}\platforms";
|
||||
Source: "c:\Users\joe\wsjt\wsjtx_install\Palettes\*.pal"; DestDir: "{app}\Palettes";
|
||||
|
||||
[Icons]
|
||||
Name: "{group}\wsjtx_w"; Filename: "{app}\wsjtx.exe"; WorkingDir: {app}; IconFilename: {app}\wsjt.ico
|
||||
Name: "{userdesktop}\wsjtx_w"; Filename: "{app}\wsjtx.exe"; WorkingDir: {app}; IconFilename: {app}\wsjt.ico
|
||||
|
||||
@@ -0,0 +1,481 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
/// \file make_gcc_workaround.hpp
|
||||
/// Special workaround code to make the make\<\> transform work on certain
|
||||
/// versions of gcc.
|
||||
//
|
||||
// Copyright 2008 Eric Niebler. Distributed under the Boost
|
||||
// Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
template<typename Tag, typename Args, long Arity >
|
||||
struct make<proto::expr<Tag, Args, Arity>()>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>()> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity >
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>()>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>()> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7 , typename A8>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A8>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7 , typename A8>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A8>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7 , typename A8 , typename A9>
|
||||
struct make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9)>
|
||||
: transform<make<proto::expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A8>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A9>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
template<typename Tag, typename Args, long Arity , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 , typename A5 , typename A6 , typename A7 , typename A8 , typename A9>
|
||||
struct make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9)>
|
||||
: transform<make<proto::basic_expr<Tag, Args, Arity>(A0 , A1 , A2 , A3 , A4 , A5 , A6 , A7 , A8 , A9)> >
|
||||
{
|
||||
template<typename Expr, typename State, typename Data>
|
||||
struct impl : transform_impl<Expr, State, Data>
|
||||
{
|
||||
typedef proto::basic_expr<Tag, Args, Arity> result_type;
|
||||
BOOST_FORCEINLINE
|
||||
result_type operator ()(
|
||||
typename impl::expr_param e
|
||||
, typename impl::state_param s
|
||||
, typename impl::data_param d
|
||||
) const
|
||||
{
|
||||
return proto::basic_expr<Tag, Args, Arity>::make(
|
||||
detail::as_lvalue( typename when<_, A0>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A1>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A2>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A3>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A4>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A5>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A6>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A7>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A8>::template impl<Expr, State, Data>()(e, s, d) ) , detail::as_lvalue( typename when<_, A9>::template impl<Expr, State, Data>()(e, s, d) )
|
||||
);
|
||||
}
|
||||
};
|
||||
};
|
||||
@@ -0,0 +1,91 @@
|
||||
// Copyright David Abrahams 2006. Distributed under the Boost
|
||||
// Software License, Version 1.0. (See accompanying
|
||||
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
#ifndef BOOST_ARCHIVE_DETAIL_REGISTER_ARCHIVE_DWA2006521_HPP
|
||||
# define BOOST_ARCHIVE_DETAIL_REGISTER_ARCHIVE_DWA2006521_HPP
|
||||
|
||||
namespace boost { namespace archive { namespace detail {
|
||||
|
||||
// No instantiate_ptr_serialization overloads generated by
|
||||
// BOOST_SERIALIZATION_REGISTER_ARCHIVE that lexically follow the call
|
||||
// will be seen *unless* they are in an associated namespace of one of
|
||||
// the arguments, so we pass one of these along to make sure this
|
||||
// namespace is considered. See temp.dep.candidate (14.6.4.2) in the
|
||||
// standard.
|
||||
struct adl_tag {};
|
||||
|
||||
template <class Archive, class Serializable>
|
||||
struct ptr_serialization_support;
|
||||
|
||||
// We could've just used ptr_serialization_support, above, but using
|
||||
// it with only a forward declaration causes vc6/7 to complain about a
|
||||
// missing instantiate member, even if it has one. This is just a
|
||||
// friendly layer of indirection.
|
||||
template <class Archive, class Serializable>
|
||||
struct _ptr_serialization_support
|
||||
: ptr_serialization_support<Archive,Serializable>
|
||||
{
|
||||
typedef int type;
|
||||
};
|
||||
|
||||
#if defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x5130)
|
||||
|
||||
template<int N>
|
||||
struct counter : counter<N-1> {};
|
||||
template<>
|
||||
struct counter<0> {};
|
||||
|
||||
template<class Serializable>
|
||||
void instantiate_ptr_serialization(Serializable* s, int, adl_tag) {
|
||||
instantiate_ptr_serialization(s, counter<20>());
|
||||
}
|
||||
|
||||
template<class Archive>
|
||||
struct get_counter {
|
||||
static const int value = sizeof(adjust_counter(counter<20>()));
|
||||
typedef counter<value> type;
|
||||
typedef counter<value - 1> prior;
|
||||
typedef char (&next)[value+1];
|
||||
};
|
||||
|
||||
char adjust_counter(counter<0>);
|
||||
template<class Serializable>
|
||||
void instantiate_ptr_serialization(Serializable*, counter<0>) {}
|
||||
|
||||
#define BOOST_SERIALIZATION_REGISTER_ARCHIVE(Archive) \
|
||||
namespace boost { namespace archive { namespace detail { \
|
||||
get_counter<Archive >::next adjust_counter(get_counter<Archive >::type);\
|
||||
template<class Serializable> \
|
||||
void instantiate_ptr_serialization(Serializable* s, \
|
||||
get_counter<Archive >::type) { \
|
||||
ptr_serialization_support<Archive, Serializable> x; \
|
||||
instantiate_ptr_serialization(s, get_counter<Archive >::prior()); \
|
||||
}\
|
||||
}}}
|
||||
|
||||
|
||||
#else
|
||||
|
||||
// This function gets called, but its only purpose is to participate
|
||||
// in overload resolution with the functions declared by
|
||||
// BOOST_SERIALIZATION_REGISTER_ARCHIVE, below.
|
||||
template <class Serializable>
|
||||
void instantiate_ptr_serialization(Serializable*, int, adl_tag ) {}
|
||||
|
||||
// The function declaration generated by this macro never actually
|
||||
// gets called, but its return type gets instantiated, and that's
|
||||
// enough to cause registration of serialization functions between
|
||||
// Archive and any exported Serializable type. See also:
|
||||
// boost/serialization/export.hpp
|
||||
# define BOOST_SERIALIZATION_REGISTER_ARCHIVE(Archive) \
|
||||
namespace boost { namespace archive { namespace detail { \
|
||||
\
|
||||
template <class Serializable> \
|
||||
typename _ptr_serialization_support<Archive, Serializable>::type \
|
||||
instantiate_ptr_serialization( Serializable*, Archive*, adl_tag ); \
|
||||
\
|
||||
}}}
|
||||
#endif
|
||||
}}} // namespace boost::archive::detail
|
||||
|
||||
#endif // BOOST_ARCHIVE_DETAIL_INSTANTIATE_SERIALIZE_DWA2006521_HPP
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
[auto_generated]
|
||||
boost/numeric/odeint/stepper/generation.hpp
|
||||
|
||||
[begin_description]
|
||||
Forward header for the factory functions. Includes all files from the generation directory.
|
||||
[end_description]
|
||||
|
||||
Copyright 2011 Karsten Ahnert
|
||||
Copyright 2011 Mario Mulansky
|
||||
|
||||
Distributed under the 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_NUMERIC_ODEINT_STEPPER_GENERATION_HPP_INCLUDED
|
||||
#define BOOST_NUMERIC_ODEINT_STEPPER_GENERATION_HPP_INCLUDED
|
||||
|
||||
#include <boost/numeric/odeint/stepper/generation/make_controlled.hpp>
|
||||
#include <boost/numeric/odeint/stepper/generation/make_dense_output.hpp>
|
||||
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_controlled_runge_kutta.hpp>
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_dense_output_runge_kutta.hpp>
|
||||
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_runge_kutta_cash_karp54_classic.hpp>
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_runge_kutta_cash_karp54.hpp>
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_runge_kutta_dopri5.hpp>
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_runge_kutta_fehlberg78.hpp>
|
||||
|
||||
|
||||
#include <boost/numeric/odeint/stepper/generation/generation_rosenbrock4.hpp>
|
||||
|
||||
|
||||
#endif // BOOST_NUMERIC_ODEINT_STEPPER_GENERATION_HPP_INCLUDED
|
||||
@@ -0,0 +1,53 @@
|
||||
/*
|
||||
Copyright Rene Rivera 2008-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)
|
||||
*/
|
||||
|
||||
#ifndef BOOST_PREDEF_LIBRARY_STD_STDCPP3_H
|
||||
#define BOOST_PREDEF_LIBRARY_STD_STDCPP3_H
|
||||
|
||||
#include <boost/predef/library/std/_prefix.h>
|
||||
|
||||
#include <boost/predef/version_number.h>
|
||||
#include <boost/predef/make.h>
|
||||
|
||||
/*`
|
||||
[heading `BOOST_LIB_STD_GNU`]
|
||||
|
||||
[@http://gcc.gnu.org/libstdc++/ GNU libstdc++] Standard C++ library.
|
||||
Version number available as year (from 1970), month, and day.
|
||||
|
||||
[table
|
||||
[[__predef_symbol__] [__predef_version__]]
|
||||
|
||||
[[`__GLIBCXX__`] [__predef_detection__]]
|
||||
[[`__GLIBCPP__`] [__predef_detection__]]
|
||||
|
||||
[[`__GLIBCXX__`] [V.R.P]]
|
||||
[[`__GLIBCPP__`] [V.R.P]]
|
||||
]
|
||||
*/
|
||||
|
||||
#define BOOST_LIB_STD_GNU BOOST_VERSION_NUMBER_NOT_AVAILABLE
|
||||
|
||||
#if defined(__GLIBCPP__) || defined(__GLIBCXX__)
|
||||
# undef BOOST_LIB_STD_GNU
|
||||
# if defined(__GLIBCXX__)
|
||||
# define BOOST_LIB_STD_GNU BOOST_PREDEF_MAKE_YYYYMMDD(__GLIBCXX__)
|
||||
# else
|
||||
# define BOOST_LIB_STD_GNU BOOST_PREDEF_MAKE_YYYYMMDD(__GLIBCPP__)
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if BOOST_LIB_STD_GNU
|
||||
# define BOOST_LIB_STD_GNU_AVAILABLE
|
||||
#endif
|
||||
|
||||
#define BOOST_LIB_STD_GNU_NAME "GNU"
|
||||
|
||||
#endif
|
||||
|
||||
#include <boost/predef/detail/test.h>
|
||||
BOOST_PREDEF_DECLARE_TEST(BOOST_LIB_STD_GNU,BOOST_LIB_STD_GNU_NAME)
|
||||
@@ -0,0 +1,41 @@
|
||||
|
||||
// (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, Howard
|
||||
// Hinnant & John Maddock 2000.
|
||||
// Use, modification and distribution are subject to the Boost Software License,
|
||||
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt).
|
||||
//
|
||||
// See http://www.boost.org/libs/type_traits for most recent version including documentation.
|
||||
|
||||
|
||||
#ifndef BOOST_TT_ADD_CV_HPP_INCLUDED
|
||||
#define BOOST_TT_ADD_CV_HPP_INCLUDED
|
||||
|
||||
#include <boost/config.hpp>
|
||||
|
||||
namespace boost {
|
||||
|
||||
// * convert a type T to a const volatile type - add_cv<T>
|
||||
// this is not required since the result is always
|
||||
// the same as "T const volatile", but it does suppress warnings
|
||||
// from some compilers:
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
// This bogus warning will appear when add_volatile is applied to a
|
||||
// const volatile reference because we can't detect const volatile
|
||||
// references with MSVC6.
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable:4181) // warning C4181: qualifier applied to reference type ignored
|
||||
#endif
|
||||
|
||||
template <class T> struct add_cv{ typedef T const volatile type; };
|
||||
|
||||
#if defined(BOOST_MSVC)
|
||||
# pragma warning(pop)
|
||||
#endif
|
||||
|
||||
template <class T> struct add_cv<T&>{ typedef T& type; };
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#endif // BOOST_TT_ADD_CV_HPP_INCLUDED
|
||||
@@ -0,0 +1,163 @@
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// (C) Copyright Ion Gaztanaga 2008-2013. Distributed under the Boost
|
||||
// Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// See http://www.boost.org/libs/container for documentation.
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP
|
||||
#define BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP
|
||||
|
||||
#ifndef BOOST_CONFIG_HPP
|
||||
# include <boost/config.hpp>
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_PRAGMA_ONCE)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
#include <boost/container/detail/config_begin.hpp>
|
||||
#include <boost/container/detail/workaround.hpp>
|
||||
#include <boost/move/utility_core.hpp>
|
||||
|
||||
#include <boost/container/detail/type_traits.hpp>
|
||||
#include <cstddef> //std::size_t
|
||||
|
||||
namespace boost {
|
||||
namespace container {
|
||||
namespace container_detail {
|
||||
|
||||
template<typename... Values>
|
||||
class tuple;
|
||||
|
||||
template<> class tuple<>
|
||||
{};
|
||||
|
||||
template<typename Head, typename... Tail>
|
||||
class tuple<Head, Tail...>
|
||||
: private tuple<Tail...>
|
||||
{
|
||||
typedef tuple<Tail...> inherited;
|
||||
|
||||
public:
|
||||
tuple()
|
||||
: inherited(), m_head()
|
||||
{}
|
||||
|
||||
template<class U, class ...Args>
|
||||
tuple(U &&u, Args && ...args)
|
||||
: inherited(::boost::forward<Args>(args)...), m_head(::boost::forward<U>(u))
|
||||
{}
|
||||
|
||||
// Construct tuple from another tuple.
|
||||
template<typename... VValues>
|
||||
tuple(const tuple<VValues...>& other)
|
||||
: inherited(other.tail()), m_head(other.head())
|
||||
{}
|
||||
|
||||
template<typename... VValues>
|
||||
tuple& operator=(const tuple<VValues...>& other)
|
||||
{
|
||||
m_head = other.head();
|
||||
tail() = other.tail();
|
||||
return this;
|
||||
}
|
||||
|
||||
typename add_reference<Head>::type head() { return m_head; }
|
||||
typename add_reference<const Head>::type head() const { return m_head; }
|
||||
|
||||
inherited& tail() { return *this; }
|
||||
const inherited& tail() const { return *this; }
|
||||
|
||||
protected:
|
||||
Head m_head;
|
||||
};
|
||||
|
||||
|
||||
template<typename... Values>
|
||||
tuple<Values&&...> forward_as_tuple(Values&&... values)
|
||||
{ return tuple<Values&&...>(::boost::forward<Values>(values)...); }
|
||||
|
||||
template<int I, typename Tuple>
|
||||
struct tuple_element;
|
||||
|
||||
template<int I, typename Head, typename... Tail>
|
||||
struct tuple_element<I, tuple<Head, Tail...> >
|
||||
{
|
||||
typedef typename tuple_element<I-1, tuple<Tail...> >::type type;
|
||||
};
|
||||
|
||||
template<typename Head, typename... Tail>
|
||||
struct tuple_element<0, tuple<Head, Tail...> >
|
||||
{
|
||||
typedef Head type;
|
||||
};
|
||||
|
||||
template<int I, typename Tuple>
|
||||
class get_impl;
|
||||
|
||||
template<int I, typename Head, typename... Values>
|
||||
class get_impl<I, tuple<Head, Values...> >
|
||||
{
|
||||
typedef typename tuple_element<I-1, tuple<Values...> >::type Element;
|
||||
typedef get_impl<I-1, tuple<Values...> > Next;
|
||||
|
||||
public:
|
||||
typedef typename add_reference<Element>::type type;
|
||||
typedef typename add_const_reference<Element>::type const_type;
|
||||
static type get(tuple<Head, Values...>& t) { return Next::get(t.tail()); }
|
||||
static const_type get(const tuple<Head, Values...>& t) { return Next::get(t.tail()); }
|
||||
};
|
||||
|
||||
template<typename Head, typename... Values>
|
||||
class get_impl<0, tuple<Head, Values...> >
|
||||
{
|
||||
public:
|
||||
typedef typename add_reference<Head>::type type;
|
||||
typedef typename add_const_reference<Head>::type const_type;
|
||||
static type get(tuple<Head, Values...>& t) { return t.head(); }
|
||||
static const_type get(const tuple<Head, Values...>& t){ return t.head(); }
|
||||
};
|
||||
|
||||
template<int I, typename... Values>
|
||||
typename get_impl<I, tuple<Values...> >::type get(tuple<Values...>& t)
|
||||
{ return get_impl<I, tuple<Values...> >::get(t); }
|
||||
|
||||
template<int I, typename... Values>
|
||||
typename get_impl<I, tuple<Values...> >::const_type get(const tuple<Values...>& t)
|
||||
{ return get_impl<I, tuple<Values...> >::get(t); }
|
||||
|
||||
////////////////////////////////////////////////////
|
||||
// Builds an index_tuple<0, 1, 2, ..., Num-1>, that will
|
||||
// be used to "unpack" into comma-separated values
|
||||
// in a function call.
|
||||
////////////////////////////////////////////////////
|
||||
|
||||
template<std::size_t...> struct index_tuple{ typedef index_tuple type; };
|
||||
|
||||
template<class S1, class S2> struct concat_index_tuple;
|
||||
|
||||
template<std::size_t... I1, std::size_t... I2>
|
||||
struct concat_index_tuple<index_tuple<I1...>, index_tuple<I2...>>
|
||||
: index_tuple<I1..., (sizeof...(I1)+I2)...>{};
|
||||
|
||||
template<std::size_t N> struct build_number_seq;
|
||||
|
||||
template<std::size_t N>
|
||||
struct build_number_seq
|
||||
: concat_index_tuple<typename build_number_seq<N/2>::type
|
||||
,typename build_number_seq<N - N/2 >::type
|
||||
>::type
|
||||
{};
|
||||
|
||||
template<> struct build_number_seq<0> : index_tuple<>{};
|
||||
template<> struct build_number_seq<1> : index_tuple<0>{};
|
||||
|
||||
}}} //namespace boost { namespace container { namespace container_detail {
|
||||
|
||||
#include <boost/container/detail/config_end.hpp>
|
||||
|
||||
#endif //#ifndef BOOST_CONTAINER_DETAIL_VARIADIC_TEMPLATES_TOOLS_HPP
|
||||
@@ -0,0 +1,18 @@
|
||||
// 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 OVERLOADS_FWD_DWA2002101_HPP
|
||||
# define OVERLOADS_FWD_DWA2002101_HPP
|
||||
|
||||
namespace boost { namespace python { namespace detail {
|
||||
|
||||
// forward declarations
|
||||
struct overloads_base;
|
||||
|
||||
template <class OverloadsT, class NameSpaceT, class SigT>
|
||||
inline void define_with_defaults(char const* name, OverloadsT const&, NameSpaceT&, SigT const&);
|
||||
|
||||
}}} // namespace boost::python::detail
|
||||
|
||||
#endif // OVERLOADS_FWD_DWA2002101_HPP
|
||||
@@ -0,0 +1,94 @@
|
||||
|
||||
// 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)
|
||||
//
|
||||
|
||||
// Preprocessed version of "boost/mpl/greater_equal.hpp" header
|
||||
// -- DO NOT modify by hand!
|
||||
|
||||
namespace boost { namespace mpl {
|
||||
|
||||
template<
|
||||
typename Tag1
|
||||
, typename Tag2
|
||||
>
|
||||
struct greater_equal_impl
|
||||
: if_c<
|
||||
( BOOST_MPL_AUX_NESTED_VALUE_WKND(int, Tag1)
|
||||
> BOOST_MPL_AUX_NESTED_VALUE_WKND(int, Tag2)
|
||||
)
|
||||
|
||||
, aux::cast2nd_impl< greater_equal_impl< Tag1,Tag1 >,Tag1, Tag2 >
|
||||
, aux::cast1st_impl< greater_equal_impl< Tag2,Tag2 >,Tag1, Tag2 >
|
||||
>::type
|
||||
{
|
||||
};
|
||||
|
||||
/// for Digital Mars C++/compilers with no CTPS/TTP support
|
||||
template<> struct greater_equal_impl< na,na >
|
||||
{
|
||||
template< typename U1, typename U2 > struct apply
|
||||
{
|
||||
typedef apply type;
|
||||
BOOST_STATIC_CONSTANT(int, value = 0);
|
||||
};
|
||||
};
|
||||
|
||||
template< typename Tag > struct greater_equal_impl< na,Tag >
|
||||
{
|
||||
template< typename U1, typename U2 > struct apply
|
||||
{
|
||||
typedef apply type;
|
||||
BOOST_STATIC_CONSTANT(int, value = 0);
|
||||
};
|
||||
};
|
||||
|
||||
template< typename Tag > struct greater_equal_impl< Tag,na >
|
||||
{
|
||||
template< typename U1, typename U2 > struct apply
|
||||
{
|
||||
typedef apply type;
|
||||
BOOST_STATIC_CONSTANT(int, value = 0);
|
||||
};
|
||||
};
|
||||
|
||||
template< typename T > struct greater_equal_tag
|
||||
{
|
||||
typedef typename T::tag type;
|
||||
};
|
||||
|
||||
template<
|
||||
typename BOOST_MPL_AUX_NA_PARAM(N1)
|
||||
, typename BOOST_MPL_AUX_NA_PARAM(N2)
|
||||
>
|
||||
struct greater_equal
|
||||
|
||||
: greater_equal_impl<
|
||||
typename greater_equal_tag<N1>::type
|
||||
, typename greater_equal_tag<N2>::type
|
||||
>::template apply< N1,N2 >::type
|
||||
{
|
||||
BOOST_MPL_AUX_LAMBDA_SUPPORT(2, greater_equal, (N1, N2))
|
||||
|
||||
};
|
||||
|
||||
BOOST_MPL_AUX_NA_SPEC2(2, 2, greater_equal)
|
||||
|
||||
}}
|
||||
|
||||
namespace boost { namespace mpl {
|
||||
|
||||
template<>
|
||||
struct greater_equal_impl< integral_c_tag,integral_c_tag >
|
||||
{
|
||||
template< typename N1, typename N2 > struct apply
|
||||
|
||||
: bool_< ( BOOST_MPL_AUX_VALUE_WKND(N1)::value >= BOOST_MPL_AUX_VALUE_WKND(N2)::value ) >
|
||||
{
|
||||
};
|
||||
};
|
||||
|
||||
}}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,35 @@
|
||||
// Boost.Units - A C++ library for zero-overhead dimensional analysis and
|
||||
// unit/quantity manipulation and conversion
|
||||
//
|
||||
// Copyright (C) 2003-2008 Matthias Christian Schabel
|
||||
// Copyright (C) 2008 Steven Watanabe
|
||||
//
|
||||
// Distributed under the Boost Software License, Version 1.0. (See
|
||||
// accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
#ifndef BOOST_UNITS_SI_MASS_HPP
|
||||
#define BOOST_UNITS_SI_MASS_HPP
|
||||
|
||||
#include <boost/units/systems/si/base.hpp>
|
||||
|
||||
namespace boost {
|
||||
|
||||
namespace units {
|
||||
|
||||
namespace si {
|
||||
|
||||
typedef unit<mass_dimension,si::system> mass;
|
||||
|
||||
BOOST_UNITS_STATIC_CONSTANT(kilogram,mass);
|
||||
BOOST_UNITS_STATIC_CONSTANT(kilograms,mass);
|
||||
BOOST_UNITS_STATIC_CONSTANT(kilogramme,mass);
|
||||
BOOST_UNITS_STATIC_CONSTANT(kilogrammes,mass);
|
||||
|
||||
} // namespace si
|
||||
|
||||
} // namespace units
|
||||
|
||||
} // namespace boost
|
||||
|
||||
#endif // BOOST_UNITS_SI_MASS_HPP
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,135 @@
|
||||
// Boost.Range library
|
||||
//
|
||||
// Copyright Thorsten Ottosen 2003-2004. Use, modification and
|
||||
// distribution is subject to the Boost Software License, Version
|
||||
// 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
// http://www.boost.org/LICENSE_1_0.txt)
|
||||
//
|
||||
// For more information, see http://www.boost.org/libs/range/
|
||||
//
|
||||
|
||||
#ifndef BOOST_RANGE_BEGIN_HPP
|
||||
#define BOOST_RANGE_BEGIN_HPP
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
# pragma once
|
||||
#endif
|
||||
|
||||
#include <boost/range/config.hpp>
|
||||
|
||||
#ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
#include <boost/range/detail/begin.hpp>
|
||||
#else
|
||||
|
||||
#include <boost/range/iterator.hpp>
|
||||
|
||||
namespace boost
|
||||
{
|
||||
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
namespace range_detail
|
||||
{
|
||||
#endif
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// primary template
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
template< typename C >
|
||||
inline BOOST_DEDUCED_TYPENAME range_iterator<C>::type
|
||||
range_begin( C& c )
|
||||
{
|
||||
//
|
||||
// If you get a compile-error here, it is most likely because
|
||||
// you have not implemented range_begin() properly in
|
||||
// the namespace of C
|
||||
//
|
||||
return c.begin();
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// pair
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
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;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// array
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
//
|
||||
// May this be discarded? Or is it needed for bad compilers?
|
||||
//
|
||||
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;
|
||||
}
|
||||
|
||||
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
} // namespace 'range_detail'
|
||||
#endif
|
||||
|
||||
// Use a ADL namespace barrier to avoid ambiguity with other unqualified
|
||||
// calls. This is particularly important with C++0x encouraging
|
||||
// unqualified calls to begin/end.
|
||||
namespace range_adl_barrier
|
||||
{
|
||||
|
||||
template< class T >
|
||||
inline BOOST_DEDUCED_TYPENAME range_iterator<T>::type begin( T& r )
|
||||
{
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
using namespace range_detail;
|
||||
#endif
|
||||
return range_begin( r );
|
||||
}
|
||||
|
||||
template< class T >
|
||||
inline BOOST_DEDUCED_TYPENAME range_iterator<const T>::type begin( const T& r )
|
||||
{
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
using namespace range_detail;
|
||||
#endif
|
||||
return range_begin( r );
|
||||
}
|
||||
|
||||
} // namespace range_adl_barrier
|
||||
} // namespace boost
|
||||
|
||||
#endif // BOOST_NO_FUNCTION_TEMPLATE_ORDERING
|
||||
|
||||
namespace boost
|
||||
{
|
||||
namespace range_adl_barrier
|
||||
{
|
||||
template< class T >
|
||||
inline BOOST_DEDUCED_TYPENAME range_iterator<const T>::type
|
||||
const_begin( const T& r )
|
||||
{
|
||||
return boost::range_adl_barrier::begin( r );
|
||||
}
|
||||
} // namespace range_adl_barrier
|
||||
|
||||
using namespace range_adl_barrier;
|
||||
} // namespace boost
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,555 @@
|
||||
/*=============================================================================
|
||||
Copyright (c) 2001-2003 Joel de Guzman
|
||||
Copyright (c) 2002-2003 Hartmut Kaiser
|
||||
http://spirit.sourceforge.net/
|
||||
|
||||
Use, modification and distribution is subject to the Boost Software
|
||||
License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
||||
http://www.boost.org/LICENSE_1_0.txt)
|
||||
=============================================================================*/
|
||||
#if !defined(BOOST_SPIRIT_PARSER_NAMES_IPP)
|
||||
#define BOOST_SPIRIT_PARSER_NAMES_IPP
|
||||
|
||||
#if defined(BOOST_SPIRIT_DEBUG)
|
||||
|
||||
#include <string>
|
||||
#include <iostream>
|
||||
#include <map>
|
||||
|
||||
#include <boost/config.hpp>
|
||||
#ifdef BOOST_NO_STRINGSTREAM
|
||||
#include <strstream>
|
||||
#define BOOST_SPIRIT_SSTREAM std::strstream
|
||||
std::string BOOST_SPIRIT_GETSTRING(std::strstream& ss)
|
||||
{
|
||||
ss << ends;
|
||||
std::string rval = ss.str();
|
||||
ss.freeze(false);
|
||||
return rval;
|
||||
}
|
||||
#else
|
||||
#include <sstream>
|
||||
#define BOOST_SPIRIT_GETSTRING(ss) ss.str()
|
||||
#define BOOST_SPIRIT_SSTREAM std::stringstream
|
||||
#endif
|
||||
|
||||
namespace boost { namespace spirit {
|
||||
|
||||
BOOST_SPIRIT_CLASSIC_NAMESPACE_BEGIN
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from actions.hpp
|
||||
template <typename ParserT, typename ActionT>
|
||||
inline std::string
|
||||
parser_name(action<ParserT, ActionT> const& p)
|
||||
{
|
||||
return std::string("action")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from directives.hpp
|
||||
template <typename ParserT>
|
||||
inline std::string
|
||||
parser_name(contiguous<ParserT> const& p)
|
||||
{
|
||||
return std::string("contiguous")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename ParserT>
|
||||
inline std::string
|
||||
parser_name(inhibit_case<ParserT> const& p)
|
||||
{
|
||||
return std::string("inhibit_case")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(longest_alternative<A, B> const& p)
|
||||
{
|
||||
return std::string("longest_alternative")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(shortest_alternative<A, B> const& p)
|
||||
{
|
||||
return std::string("shortest_alternative")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from numerics.hpp
|
||||
template <typename T, int Radix, unsigned MinDigits, int MaxDigits>
|
||||
inline std::string
|
||||
parser_name(uint_parser<T, Radix, MinDigits, MaxDigits> const& p)
|
||||
{
|
||||
BOOST_SPIRIT_SSTREAM stream;
|
||||
stream << Radix << ", " << MinDigits << ", " << MaxDigits;
|
||||
return std::string("uint_parser<")
|
||||
+ BOOST_SPIRIT_GETSTRING(stream)
|
||||
+ std::string(">");
|
||||
}
|
||||
|
||||
template <typename T, int Radix, unsigned MinDigits, int MaxDigits>
|
||||
inline std::string
|
||||
parser_name(int_parser<T, Radix, MinDigits, MaxDigits> const& p)
|
||||
{
|
||||
BOOST_SPIRIT_SSTREAM stream;
|
||||
stream << Radix << ", " << MinDigits << ", " << MaxDigits;
|
||||
return std::string("int_parser<")
|
||||
+ BOOST_SPIRIT_GETSTRING(stream)
|
||||
+ std::string(">");
|
||||
}
|
||||
|
||||
template <typename T, typename RealPoliciesT>
|
||||
inline std::string
|
||||
parser_name(real_parser<T, RealPoliciesT> const& p)
|
||||
{
|
||||
return std::string("real_parser");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from operators.hpp
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(sequence<A, B> const& p)
|
||||
{
|
||||
return std::string("sequence")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(sequential_or<A, B> const& p)
|
||||
{
|
||||
return std::string("sequential_or")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(alternative<A, B> const& p)
|
||||
{
|
||||
return std::string("alternative")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(intersection<A, B> const& p)
|
||||
{
|
||||
return std::string("intersection")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(difference<A, B> const& p)
|
||||
{
|
||||
return std::string("difference")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename A, typename B>
|
||||
inline std::string
|
||||
parser_name(exclusive_or<A, B> const& p)
|
||||
{
|
||||
return std::string("exclusive_or")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.left()) + std::string(", ") + parser_name(p.right())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename S>
|
||||
inline std::string
|
||||
parser_name(optional<S> const& p)
|
||||
{
|
||||
return std::string("optional")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename S>
|
||||
inline std::string
|
||||
parser_name(kleene_star<S> const& p)
|
||||
{
|
||||
return std::string("kleene_star")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
template <typename S>
|
||||
inline std::string
|
||||
parser_name(positive<S> const& p)
|
||||
{
|
||||
return std::string("positive")
|
||||
+ std::string("[")
|
||||
+ parser_name(p.subject())
|
||||
+ std::string("]");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from parser.hpp
|
||||
template <typename DerivedT>
|
||||
inline std::string
|
||||
parser_name(parser<DerivedT> const& p)
|
||||
{
|
||||
return std::string("parser");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from primitives.hpp
|
||||
template <typename DerivedT>
|
||||
inline std::string
|
||||
parser_name(char_parser<DerivedT> const &p)
|
||||
{
|
||||
return std::string("char_parser");
|
||||
}
|
||||
|
||||
template <typename CharT>
|
||||
inline std::string
|
||||
parser_name(chlit<CharT> const &p)
|
||||
{
|
||||
return std::string("chlit(\'")
|
||||
+ std::string(1, p.ch)
|
||||
+ std::string("\')");
|
||||
}
|
||||
|
||||
template <typename CharT>
|
||||
inline std::string
|
||||
parser_name(range<CharT> const &p)
|
||||
{
|
||||
return std::string("range(")
|
||||
+ std::string(1, p.first) + std::string(", ") + std::string(1, p.last)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
template <typename IteratorT>
|
||||
inline std::string
|
||||
parser_name(chseq<IteratorT> const &p)
|
||||
{
|
||||
return std::string("chseq(\"")
|
||||
+ std::string(p.first, p.last)
|
||||
+ std::string("\")");
|
||||
}
|
||||
|
||||
template <typename IteratorT>
|
||||
inline std::string
|
||||
parser_name(strlit<IteratorT> const &p)
|
||||
{
|
||||
return std::string("strlit(\"")
|
||||
+ std::string(p.seq.first, p.seq.last)
|
||||
+ std::string("\")");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(nothing_parser const&)
|
||||
{
|
||||
return std::string("nothing");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(epsilon_parser const&)
|
||||
{
|
||||
return std::string("epsilon");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(anychar_parser const&)
|
||||
{
|
||||
return std::string("anychar");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(alnum_parser const&)
|
||||
{
|
||||
return std::string("alnum");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(alpha_parser const&)
|
||||
{
|
||||
return std::string("alpha");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(cntrl_parser const&)
|
||||
{
|
||||
return std::string("cntrl");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(digit_parser const&)
|
||||
{
|
||||
return std::string("digit");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(graph_parser const&)
|
||||
{
|
||||
return std::string("graph");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(lower_parser const&)
|
||||
{
|
||||
return std::string("lower");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(print_parser const&)
|
||||
{
|
||||
return std::string("print");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(punct_parser const&)
|
||||
{
|
||||
return std::string("punct");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(blank_parser const&)
|
||||
{
|
||||
return std::string("blank");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(space_parser const&)
|
||||
{
|
||||
return std::string("space");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(upper_parser const&)
|
||||
{
|
||||
return std::string("upper");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(xdigit_parser const&)
|
||||
{
|
||||
return std::string("xdigit");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(eol_parser const&)
|
||||
{
|
||||
return std::string("eol");
|
||||
}
|
||||
|
||||
inline std::string
|
||||
parser_name(end_parser const&)
|
||||
{
|
||||
return std::string("end");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from rule.hpp
|
||||
namespace impl {
|
||||
struct node_registry
|
||||
{
|
||||
typedef std::pair<std::string, bool> rule_info;
|
||||
typedef std::map<void const *, rule_info> rule_infos;
|
||||
|
||||
std::string find_node(void const *r)
|
||||
{
|
||||
rule_infos::const_iterator cit = infos.find(r);
|
||||
if (cit != infos.end())
|
||||
return (*cit).second.first;
|
||||
return std::string("<unknown>");
|
||||
}
|
||||
|
||||
bool trace_node(void const *r)
|
||||
{
|
||||
rule_infos::const_iterator cit = infos.find(r);
|
||||
if (cit != infos.end())
|
||||
return (*cit).second.second;
|
||||
return BOOST_SPIRIT_DEBUG_TRACENODE;
|
||||
}
|
||||
|
||||
bool register_node(void const *r, char const *name_to_register,
|
||||
bool trace_node)
|
||||
{
|
||||
if (infos.find(r) != infos.end())
|
||||
return false;
|
||||
|
||||
return infos.insert(rule_infos::value_type(r,
|
||||
rule_info(std::string(name_to_register), trace_node))
|
||||
).second;
|
||||
}
|
||||
|
||||
bool unregister_node(void const *r)
|
||||
{
|
||||
if (infos.find(r) == infos.end())
|
||||
return false;
|
||||
return (1 == infos.erase(r));
|
||||
}
|
||||
|
||||
private:
|
||||
rule_infos infos;
|
||||
};
|
||||
|
||||
inline node_registry &
|
||||
get_node_registry()
|
||||
{
|
||||
static node_registry node_infos;
|
||||
return node_infos;
|
||||
}
|
||||
} // namespace impl
|
||||
|
||||
template<
|
||||
typename DerivedT, typename EmbedT,
|
||||
typename T0, typename T1, typename T2
|
||||
>
|
||||
inline std::string
|
||||
parser_name(impl::rule_base<DerivedT, EmbedT, T0, T1, T2> const& p)
|
||||
{
|
||||
return std::string("rule_base")
|
||||
+ std::string("(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
template<typename T0, typename T1, typename T2>
|
||||
inline std::string
|
||||
parser_name(rule<T0, T1, T2> const& p)
|
||||
{
|
||||
return std::string("rule")
|
||||
+ std::string("(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from subrule.hpp
|
||||
template <typename FirstT, typename RestT>
|
||||
inline std::string
|
||||
parser_name(subrule_list<FirstT, RestT> const &p)
|
||||
{
|
||||
return std::string("subrule_list")
|
||||
+ std::string("(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
template <int ID, typename DefT, typename ContextT>
|
||||
inline std::string
|
||||
parser_name(subrule_parser<ID, DefT, ContextT> const &p)
|
||||
{
|
||||
return std::string("subrule_parser")
|
||||
+ std::string("(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
template <int ID, typename ContextT>
|
||||
inline std::string
|
||||
parser_name(subrule<ID, ContextT> const &p)
|
||||
{
|
||||
BOOST_SPIRIT_SSTREAM stream;
|
||||
stream << ID;
|
||||
return std::string("subrule<")
|
||||
+ BOOST_SPIRIT_GETSTRING(stream)
|
||||
+ std::string(">(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// from grammar.hpp
|
||||
template <typename DerivedT, typename ContextT>
|
||||
inline std::string
|
||||
parser_name(grammar<DerivedT, ContextT> const& p)
|
||||
{
|
||||
return std::string("grammar")
|
||||
+ std::string("(")
|
||||
+ impl::get_node_registry().find_node(&p)
|
||||
+ std::string(")");
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// decide, if a node is to be traced or not
|
||||
template<
|
||||
typename DerivedT, typename EmbedT,
|
||||
typename T0, typename T1, typename T2
|
||||
>
|
||||
inline bool
|
||||
trace_parser(impl::rule_base<DerivedT, EmbedT, T0, T1, T2>
|
||||
const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
template<typename T0, typename T1, typename T2>
|
||||
inline bool
|
||||
trace_parser(rule<T0, T1, T2> const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
template <typename DerivedT, typename ContextT>
|
||||
inline bool
|
||||
trace_parser(grammar<DerivedT, ContextT> const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
template <typename DerivedT, int N, typename ContextT>
|
||||
inline bool
|
||||
trace_parser(impl::entry_grammar<DerivedT, N, ContextT> const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
template <int ID, typename ContextT>
|
||||
bool
|
||||
trace_parser(subrule<ID, ContextT> const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
template <typename ParserT, typename ActorTupleT>
|
||||
bool
|
||||
trace_parser(init_closure_parser<ParserT, ActorTupleT> const& p)
|
||||
{
|
||||
return impl::get_node_registry().trace_node(&p);
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
BOOST_SPIRIT_CLASSIC_NAMESPACE_END
|
||||
|
||||
}} // namespace boost::spirit
|
||||
|
||||
#undef BOOST_SPIRIT_SSTREAM
|
||||
#undef BOOST_SPIRIT_GETSTRING
|
||||
|
||||
#endif // defined(BOOST_SPIRIT_DEBUG)
|
||||
|
||||
#endif // !defined(BOOST_SPIRIT_PARSER_NAMES_IPP)
|
||||
@@ -0,0 +1,32 @@
|
||||
subroutine fqso_first(nfqso,ntol,ca,ncand)
|
||||
|
||||
! If a candidate was found within +/- ntol of nfqso, move it into ca(1).
|
||||
|
||||
type candidate
|
||||
real freq
|
||||
real dt
|
||||
real sync
|
||||
real flip
|
||||
end type candidate
|
||||
type(candidate) ca(300),cb
|
||||
|
||||
dmin=1.e30
|
||||
i0=0
|
||||
do i=1,ncand
|
||||
d=abs(ca(i)%freq-nfqso)
|
||||
if(d.lt.dmin) then
|
||||
i0=i
|
||||
dmin=d
|
||||
endif
|
||||
enddo
|
||||
|
||||
if(dmin.lt.float(ntol)) then
|
||||
cb=ca(i0)
|
||||
do i=i0,2,-1
|
||||
ca(i)=ca(i-1)
|
||||
enddo
|
||||
ca(1)=cb
|
||||
endif
|
||||
|
||||
return
|
||||
end subroutine fqso_first
|
||||
@@ -0,0 +1,221 @@
|
||||
// (C) Copyright John Maddock 2001 - 2003.
|
||||
// (C) Copyright David Abrahams 2002 - 2003.
|
||||
// (C) Copyright Aleksey Gurtovoy 2002.
|
||||
// Use, modification and distribution are subject to the
|
||||
// Boost Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org for most recent version.
|
||||
|
||||
// CodeGear C++ compiler setup:
|
||||
|
||||
#if !defined( BOOST_WITH_CODEGEAR_WARNINGS )
|
||||
// these warnings occur frequently in optimized template code
|
||||
# pragma warn -8004 // var assigned value, but never used
|
||||
# pragma warn -8008 // condition always true/false
|
||||
# pragma warn -8066 // dead code can never execute
|
||||
# pragma warn -8104 // static members with ctors not threadsafe
|
||||
# pragma warn -8105 // reference member in class without ctors
|
||||
#endif
|
||||
//
|
||||
// versions check:
|
||||
// last known and checked version is 0x621
|
||||
#if (__CODEGEARC__ > 0x621)
|
||||
# if defined(BOOST_ASSERT_CONFIG)
|
||||
# error "Unknown compiler version - please run the configure tests and report the results"
|
||||
# else
|
||||
# pragma message( "Unknown compiler version - please run the configure tests and report the results")
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// CodeGear C++ Builder 2009
|
||||
#if (__CODEGEARC__ <= 0x613)
|
||||
# define BOOST_NO_INTEGRAL_INT64_T
|
||||
# define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
|
||||
# define BOOST_NO_PRIVATE_IN_AGGREGATE
|
||||
# define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
|
||||
// we shouldn't really need this - but too many things choke
|
||||
// without it, this needs more investigation:
|
||||
# define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
|
||||
# define BOOST_SP_NO_SP_CONVERTIBLE
|
||||
#endif
|
||||
|
||||
// CodeGear C++ Builder 2010
|
||||
#if (__CODEGEARC__ <= 0x621)
|
||||
# define BOOST_NO_TYPENAME_WITH_CTOR // Cannot use typename keyword when making temporaries of a dependant type
|
||||
# define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
|
||||
# define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
||||
# define BOOST_NO_NESTED_FRIENDSHIP // TC1 gives nested classes access rights as any other member
|
||||
# define BOOST_NO_USING_TEMPLATE
|
||||
# define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
||||
// Temporary hack, until specific MPL preprocessed headers are generated
|
||||
# define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
|
||||
|
||||
// CodeGear has not yet completely implemented value-initialization, for
|
||||
// example for array types, as I reported in 2010: Embarcadero Report 83751,
|
||||
// "Value-initialization: arrays should have each element value-initialized",
|
||||
// http://qc.embarcadero.com/wc/qcmain.aspx?d=83751
|
||||
// Last checked version: Embarcadero C++ 6.21
|
||||
// See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues
|
||||
// (Niels Dekker, LKEB, April 2010)
|
||||
# define BOOST_NO_COMPLETE_VALUE_INITIALIZATION
|
||||
|
||||
# if defined(NDEBUG) && defined(__cplusplus)
|
||||
// fix broken <cstring> so that Boost.test works:
|
||||
# include <cstring>
|
||||
# undef strcmp
|
||||
# endif
|
||||
// fix broken errno declaration:
|
||||
# include <errno.h>
|
||||
# ifndef errno
|
||||
# define errno errno
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
// Reportedly, #pragma once is supported since C++ Builder 2010
|
||||
#if (__CODEGEARC__ >= 0x620)
|
||||
# define BOOST_HAS_PRAGMA_ONCE
|
||||
#endif
|
||||
|
||||
//
|
||||
// C++0x macros:
|
||||
//
|
||||
#if (__CODEGEARC__ <= 0x620)
|
||||
#define BOOST_NO_CXX11_STATIC_ASSERT
|
||||
#else
|
||||
#define BOOST_HAS_STATIC_ASSERT
|
||||
#endif
|
||||
#define BOOST_HAS_CHAR16_T
|
||||
#define BOOST_HAS_CHAR32_T
|
||||
#define BOOST_HAS_LONG_LONG
|
||||
// #define BOOST_HAS_ALIGNOF
|
||||
#define BOOST_HAS_DECLTYPE
|
||||
#define BOOST_HAS_EXPLICIT_CONVERSION_OPS
|
||||
// #define BOOST_HAS_RVALUE_REFS
|
||||
#define BOOST_HAS_SCOPED_ENUM
|
||||
// #define BOOST_HAS_STATIC_ASSERT
|
||||
#define BOOST_HAS_STD_TYPE_TRAITS
|
||||
|
||||
#define BOOST_NO_CXX11_AUTO_DECLARATIONS
|
||||
#define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS
|
||||
#define BOOST_NO_CXX11_CONSTEXPR
|
||||
#define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS
|
||||
#define BOOST_NO_CXX11_DELETED_FUNCTIONS
|
||||
#define BOOST_NO_CXX11_EXTERN_TEMPLATE
|
||||
#define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS
|
||||
#define BOOST_NO_CXX11_LAMBDAS
|
||||
#define BOOST_NO_CXX11_LOCAL_CLASS_TEMPLATE_PARAMETERS
|
||||
#define BOOST_NO_CXX11_NOEXCEPT
|
||||
#define BOOST_NO_CXX11_NULLPTR
|
||||
#define BOOST_NO_CXX11_RANGE_BASED_FOR
|
||||
#define BOOST_NO_CXX11_RAW_LITERALS
|
||||
#define BOOST_NO_CXX11_RVALUE_REFERENCES
|
||||
#define BOOST_NO_SFINAE_EXPR
|
||||
#define BOOST_NO_CXX11_TEMPLATE_ALIASES
|
||||
#define BOOST_NO_CXX11_UNICODE_LITERALS
|
||||
#define BOOST_NO_CXX11_VARIADIC_TEMPLATES
|
||||
#define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX
|
||||
#define BOOST_NO_CXX11_USER_DEFINED_LITERALS
|
||||
#define BOOST_NO_CXX11_ALIGNAS
|
||||
#define BOOST_NO_CXX11_TRAILING_RESULT_TYPES
|
||||
#define BOOST_NO_CXX11_INLINE_NAMESPACES
|
||||
#define BOOST_NO_CXX11_REF_QUALIFIERS
|
||||
#define BOOST_NO_CXX11_FINAL
|
||||
#define BOOST_NO_CXX11_THREAD_LOCAL
|
||||
|
||||
// C++ 14:
|
||||
#if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304)
|
||||
# define BOOST_NO_CXX14_AGGREGATE_NSDMI
|
||||
#endif
|
||||
#if !defined(__cpp_binary_literals) || (__cpp_binary_literals < 201304)
|
||||
# define BOOST_NO_CXX14_BINARY_LITERALS
|
||||
#endif
|
||||
#if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304)
|
||||
# define BOOST_NO_CXX14_CONSTEXPR
|
||||
#endif
|
||||
#if !defined(__cpp_decltype_auto) || (__cpp_decltype_auto < 201304)
|
||||
# define BOOST_NO_CXX14_DECLTYPE_AUTO
|
||||
#endif
|
||||
#if (__cplusplus < 201304) // There's no SD6 check for this....
|
||||
# define BOOST_NO_CXX14_DIGIT_SEPARATORS
|
||||
#endif
|
||||
#if !defined(__cpp_generic_lambdas) || (__cpp_generic_lambdas < 201304)
|
||||
# define BOOST_NO_CXX14_GENERIC_LAMBDAS
|
||||
#endif
|
||||
#if !defined(__cpp_init_captures) || (__cpp_init_captures < 201304)
|
||||
# define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES
|
||||
#endif
|
||||
#if !defined(__cpp_return_type_deduction) || (__cpp_return_type_deduction < 201304)
|
||||
# define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION
|
||||
#endif
|
||||
#if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304)
|
||||
# define BOOST_NO_CXX14_VARIABLE_TEMPLATES
|
||||
#endif
|
||||
|
||||
//
|
||||
// TR1 macros:
|
||||
//
|
||||
#define BOOST_HAS_TR1_HASH
|
||||
#define BOOST_HAS_TR1_TYPE_TRAITS
|
||||
#define BOOST_HAS_TR1_UNORDERED_MAP
|
||||
#define BOOST_HAS_TR1_UNORDERED_SET
|
||||
|
||||
#define BOOST_HAS_MACRO_USE_FACET
|
||||
|
||||
#define BOOST_NO_CXX11_HDR_INITIALIZER_LIST
|
||||
|
||||
// On non-Win32 platforms let the platform config figure this out:
|
||||
#ifdef _WIN32
|
||||
# define BOOST_HAS_STDINT_H
|
||||
#endif
|
||||
|
||||
//
|
||||
// __int64:
|
||||
//
|
||||
#if !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_MS_INT64
|
||||
#endif
|
||||
//
|
||||
// check for exception handling support:
|
||||
//
|
||||
#if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS) && !defined(BOOST_NO_EXCEPTIONS)
|
||||
# define BOOST_NO_EXCEPTIONS
|
||||
#endif
|
||||
//
|
||||
// all versions have a <dirent.h>:
|
||||
//
|
||||
#if !defined(__STRICT_ANSI__)
|
||||
# define BOOST_HAS_DIRENT_H
|
||||
#endif
|
||||
//
|
||||
// all versions support __declspec:
|
||||
//
|
||||
#if defined(__STRICT_ANSI__)
|
||||
// config/platform/win32.hpp will define BOOST_SYMBOL_EXPORT, etc., unless already defined
|
||||
# define BOOST_SYMBOL_EXPORT
|
||||
#endif
|
||||
//
|
||||
// ABI fixing headers:
|
||||
//
|
||||
#ifndef BOOST_ABI_PREFIX
|
||||
# define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp"
|
||||
#endif
|
||||
#ifndef BOOST_ABI_SUFFIX
|
||||
# define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp"
|
||||
#endif
|
||||
//
|
||||
// Disable Win32 support in ANSI mode:
|
||||
//
|
||||
# pragma defineonoption BOOST_DISABLE_WIN32 -A
|
||||
//
|
||||
// MSVC compatibility mode does some nasty things:
|
||||
// TODO: look up if this doesn't apply to the whole 12xx range
|
||||
//
|
||||
#if defined(_MSC_VER) && (_MSC_VER <= 1200)
|
||||
# define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
|
||||
# define BOOST_NO_VOID_RETURNS
|
||||
#endif
|
||||
|
||||
#define BOOST_COMPILER "CodeGear C++ version " BOOST_STRINGIZE(__CODEGEARC__)
|
||||
|
||||
@@ -0,0 +1,173 @@
|
||||
/* ENC.C - Encoding procedures. */
|
||||
|
||||
/* Copyright (c) 1995-2012 by Radford M. Neal.
|
||||
*
|
||||
* Permission is granted for anyone to copy, use, modify, and distribute
|
||||
* these programs and accompanying documents for any purpose, provided
|
||||
* this copyright notice is retained and prominently displayed, and note
|
||||
* is made of any changes made to these programs. These programs and
|
||||
* documents are distributed without any warranty, express or implied.
|
||||
* As the programs were written for research purposes only, they have not
|
||||
* been tested to the degree that would be advisable in any important
|
||||
* application. All use of these programs is entirely at the user's own
|
||||
* risk.
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
|
||||
/*#include "rand.h"*/
|
||||
#include "alloc.h"
|
||||
#include "mod2sparse.h"
|
||||
#include "mod2dense.h"
|
||||
#include "mod2convert.h"
|
||||
#include "rcode.h"
|
||||
#include "enc.h"
|
||||
|
||||
|
||||
/* The procedures in this module obtain the generator matrix to use for
|
||||
encoding from the global variables declared in rcode.h */
|
||||
|
||||
|
||||
/* ENCODE A BLOCK USING A SPARSE REPRESENTATION OF THE GENERATOR MATRIX. */
|
||||
|
||||
void sparse_encode
|
||||
( char *sblk,
|
||||
char *cblk
|
||||
)
|
||||
{
|
||||
int i, j;
|
||||
|
||||
mod2entry *e;
|
||||
char *x, *y;
|
||||
|
||||
x = chk_alloc (M, sizeof *x);
|
||||
y = chk_alloc (M, sizeof *y);
|
||||
|
||||
/* Multiply the vector of source bits by the systematic columns of the
|
||||
parity check matrix, giving x. Also copy these bits to the coded block. */
|
||||
|
||||
for (i = 0; i<M; i++) x[i] = 0;
|
||||
|
||||
for (j = M; j<N; j++)
|
||||
{
|
||||
cblk[cols[j]] = sblk[j-M];
|
||||
|
||||
if (sblk[j-M]==1)
|
||||
{ for (e = mod2sparse_first_in_col(H,cols[j]);
|
||||
!mod2sparse_at_end(e);
|
||||
e = mod2sparse_next_in_col(e))
|
||||
{ x[mod2sparse_row(e)] ^= 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Solve Ly=x for y by forward substitution, then U(cblk)=y by backward
|
||||
substitution. */
|
||||
|
||||
if (!mod2sparse_forward_sub(L,rows,x,y)
|
||||
|| !mod2sparse_backward_sub(U,cols,y,cblk))
|
||||
{
|
||||
abort(); /* Shouldn't occur, even if the parity check matrix has
|
||||
redundant rows */
|
||||
}
|
||||
|
||||
free(x);
|
||||
free(y);
|
||||
}
|
||||
|
||||
|
||||
/* ENCODE A BLOCK USING DENSE REPRESENTATION OF GENERATOR MATRIX. */
|
||||
|
||||
void dense_encode
|
||||
( char *sblk,
|
||||
char *cblk,
|
||||
mod2dense *u,
|
||||
mod2dense *v
|
||||
)
|
||||
{
|
||||
int j;
|
||||
|
||||
/* Copy source bits to the systematic part of the coded block. */
|
||||
|
||||
for (j = M; j<N; j++)
|
||||
{ cblk[cols[j]] = sblk[j-M];
|
||||
}
|
||||
|
||||
/* Multiply by Inv(A) X B to produce check bits. */
|
||||
|
||||
for (j = M; j<N; j++)
|
||||
{ mod2dense_set(u,j-M,0,sblk[j-M]);
|
||||
}
|
||||
|
||||
mod2dense_multiply(G,u,v);
|
||||
|
||||
/* Copy check bits to the right places in the coded block. */
|
||||
|
||||
for (j = 0; j<M; j++)
|
||||
{ cblk[cols[j]] = mod2dense_get(v,j,0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* ENCODE A BLOCK USING MIXED REPRESENTATION OF GENERATOR MATRIX. */
|
||||
|
||||
void mixed_encode
|
||||
( char *sblk,
|
||||
char *cblk,
|
||||
mod2dense *u,
|
||||
mod2dense *v
|
||||
)
|
||||
{
|
||||
mod2entry *e;
|
||||
int j;
|
||||
|
||||
/* Multiply the vector of source bits by the message bit columns of the
|
||||
parity check matrix. Also copy these bits to the coded block. Take
|
||||
account of how columns have been reordered. */
|
||||
|
||||
mod2dense_clear(u);
|
||||
|
||||
for (j = M; j<N; j++)
|
||||
{
|
||||
cblk[cols[j]] = sblk[j-M];
|
||||
|
||||
if (sblk[j-M]==1)
|
||||
{ for (e = mod2sparse_first_in_col(H,cols[j]);
|
||||
!mod2sparse_at_end(e);
|
||||
e = mod2sparse_next_in_col(e))
|
||||
{ (void) mod2dense_flip(u,mod2sparse_row(e),0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Multiply by Inv(A) to produce check bits. */
|
||||
|
||||
mod2dense_multiply(G,u,v);
|
||||
|
||||
/* Copy check bits to the right places in the coded block. */
|
||||
|
||||
for (j = 0; j<M; j++)
|
||||
{ cblk[cols[j]] = mod2dense_get(v,j,0);
|
||||
}
|
||||
}
|
||||
|
||||
// Wrapper for calling sparse_encode from fortran
|
||||
void ldpc_encode_(
|
||||
char msg[N-M],
|
||||
char cdw[N]
|
||||
){
|
||||
int i;
|
||||
char checks[M];
|
||||
|
||||
sparse_encode(msg,cdw);
|
||||
mod2sparse_mulvec (H, cdw, checks);
|
||||
for (i = 0; i<M; i++) {
|
||||
if( checks[i] == 1 ) {
|
||||
printf("Failed to encode.\n");
|
||||
abort();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 25 KiB |
@@ -0,0 +1,64 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// internals_fwd.hpp : forward declarations, for internal headers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// Copyright Samuel Krempp 2003. Use, modification, and distribution are
|
||||
// subject to the Boost Software License, Version 1.0. (See accompanying
|
||||
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/libs/format for library home page
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#ifndef BOOST_FORMAT_INTERNAL_FWD_HPP
|
||||
#define BOOST_FORMAT_INTERNAL_FWD_HPP
|
||||
|
||||
#include <boost/format/format_fwd.hpp>
|
||||
#include <boost/config.hpp>
|
||||
|
||||
|
||||
namespace boost {
|
||||
namespace io {
|
||||
|
||||
namespace detail {
|
||||
template<class Ch, class Tr> struct stream_format_state;
|
||||
template<class Ch, class Tr, class Alloc> struct format_item;
|
||||
|
||||
|
||||
// these functions were intended as methods,
|
||||
// but MSVC have problems with template member functions :
|
||||
// defined in format_implementation.hpp :
|
||||
template<class Ch, class Tr, class Alloc, class T>
|
||||
basic_format<Ch, Tr, Alloc>&
|
||||
modify_item_body (basic_format<Ch, Tr, Alloc>& self,
|
||||
int itemN, T manipulator);
|
||||
|
||||
template<class Ch, class Tr, class Alloc, class T>
|
||||
basic_format<Ch, Tr, Alloc>&
|
||||
bind_arg_body (basic_format<Ch, Tr, Alloc>& self,
|
||||
int argN, const T& val);
|
||||
|
||||
// in internals.hpp :
|
||||
template<class Ch, class Tr, class T>
|
||||
void apply_manip_body (stream_format_state<Ch, Tr>& self,
|
||||
T manipulator);
|
||||
|
||||
// argument feeding (defined in feed_args.hpp ) :
|
||||
template<class Ch, class Tr, class Alloc, class T>
|
||||
void distribute (basic_format<Ch,Tr, Alloc>& self, T x);
|
||||
|
||||
template<class Ch, class Tr, class Alloc, class T>
|
||||
basic_format<Ch, Tr, Alloc>&
|
||||
feed (basic_format<Ch,Tr, Alloc>& self, T x);
|
||||
|
||||
template<class Ch, class Tr, class Alloc, class T>
|
||||
basic_format<Ch, Tr, Alloc>&
|
||||
feed_impl (basic_format<Ch,Tr, Alloc>& self, T x);
|
||||
|
||||
} // namespace detail
|
||||
|
||||
} // namespace io
|
||||
} // namespace boost
|
||||
|
||||
|
||||
#endif // BOOST_FORMAT_INTERNAL_FWD_HPP
|
||||
@@ -0,0 +1,33 @@
|
||||
#if !defined(BOOST_PHOENIX_DONT_USE_PREPROCESSED_FILES)
|
||||
|
||||
#include <boost/phoenix/operator/detail/cpp03/preprocessed/mem_fun_ptr_expr.hpp>
|
||||
|
||||
#else
|
||||
|
||||
#if defined(__WAVE__) && defined(BOOST_PHOENIX_CREATE_PREPROCESSED_FILES)
|
||||
#pragma wave option(preserve: 2, line: 0, output: "preprocessed/mem_fun_ptr_expr_" BOOST_PHOENIX_LIMIT_STR ".hpp")
|
||||
#endif
|
||||
/*==============================================================================
|
||||
Copyright (c) 2016 Kohei Takahashi
|
||||
|
||||
Distributed under the Boost Software License, Version 1.0. (See accompanying
|
||||
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
==============================================================================*/
|
||||
|
||||
#if defined(__WAVE__) && defined(BOOST_PHOENIX_CREATE_PREPROCESSED_FILES)
|
||||
#pragma wave option(preserve: 1)
|
||||
#endif
|
||||
|
||||
BOOST_PHOENIX_DEFINE_EXPRESSION_VARARG(
|
||||
(boost)(phoenix)(mem_fun_ptr)
|
||||
, (meta_grammar)
|
||||
(meta_grammar)
|
||||
, BOOST_PHOENIX_LIMIT
|
||||
)
|
||||
|
||||
#if defined(__WAVE__) && defined(BOOST_PHOENIX_CREATE_PREPROCESSED_FILES)
|
||||
#pragma wave option(output: null)
|
||||
#endif
|
||||
|
||||
#endif // BOOST_PHOENIX_DONT_USE_PREPROCESSED_FILES
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user