mirror of
https://github.com/boostorg/parameter.git
synced 2026-01-20 04:42:22 +00:00
Compare commits
103 Commits
sandbox-br
...
boost-1.65
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
247536c841 | ||
|
|
fd4a18d490 | ||
|
|
a2da4c32f5 | ||
|
|
a3b5ce8a93 | ||
|
|
612563e0fe | ||
|
|
904e2f5020 | ||
|
|
c303922fe9 | ||
|
|
9a8ad86fd7 | ||
|
|
0461c0a070 | ||
|
|
6ad2d6b207 | ||
|
|
45eebd0b85 | ||
|
|
d6132a7645 | ||
|
|
3462c3dc06 | ||
|
|
bc19656218 | ||
|
|
09cc5cf219 | ||
|
|
dd466e7d54 | ||
|
|
368205ab37 | ||
|
|
9821c1a5f9 | ||
|
|
d3a422ba6e | ||
|
|
aaf00c5449 | ||
|
|
a9a4287f4d | ||
|
|
e1f43668e7 | ||
|
|
3b34198a6f | ||
|
|
49ab4faa2b | ||
|
|
54854d4a3a | ||
|
|
45295c87bc | ||
|
|
0dcd40da74 | ||
|
|
a510824ee4 | ||
|
|
7465ba08d3 | ||
|
|
8dca3b7307 | ||
|
|
51a02e0822 | ||
|
|
a07961f561 | ||
|
|
4e26b448e9 | ||
|
|
b5e57e0024 | ||
|
|
b74489d477 | ||
|
|
475001a591 | ||
|
|
f9e0d1c5c3 | ||
|
|
bdcbf442bf | ||
|
|
c9cf0ab0f5 | ||
|
|
20301b3da4 | ||
|
|
59e172adb3 | ||
|
|
9f4334c1c1 | ||
|
|
7ff5c4b996 | ||
|
|
1b1499b94c | ||
|
|
3cf03f73ca | ||
|
|
04cea6497d | ||
|
|
e6eda9a776 | ||
|
|
8a404e2d67 | ||
|
|
31f9f620fe | ||
|
|
56ddeddfaf | ||
|
|
fe43dad724 | ||
|
|
ce2d43c1b5 | ||
|
|
86d7201a99 | ||
|
|
ccf40a29c1 | ||
|
|
28ed7b9704 | ||
|
|
6c3ee189d1 | ||
|
|
15048a1d82 | ||
|
|
3852ff760c | ||
|
|
916b4d2c2f | ||
|
|
af9b04e7ad | ||
|
|
894dffe6ff | ||
|
|
c17ea8d26d | ||
|
|
1844c27699 | ||
|
|
9694b76bf2 | ||
|
|
7c9ddf23e0 | ||
|
|
224d313a05 | ||
|
|
47c53efbaa | ||
|
|
57ef2b6ee9 | ||
|
|
297e85c0f1 | ||
|
|
3a59d2cea3 | ||
|
|
58bb633dc0 | ||
|
|
3397bafb4a | ||
|
|
cc256f0bb3 | ||
|
|
e3b060b3e5 | ||
|
|
0791667e33 | ||
|
|
91ffd43483 | ||
|
|
fa751e022e | ||
|
|
1f6c9a3034 | ||
|
|
6c209395aa | ||
|
|
5231f04b27 | ||
|
|
c7258e9c9e | ||
|
|
22a1f905e9 | ||
|
|
0417a36693 | ||
|
|
d42b860b8d | ||
|
|
c5168be5d7 | ||
|
|
c29a75c9df | ||
|
|
e18d621508 | ||
|
|
40399d3505 | ||
|
|
d6db8c6216 | ||
|
|
38817a8bb5 | ||
|
|
646c519dc0 | ||
|
|
cb501f9f38 | ||
|
|
7eb7737095 | ||
|
|
bfc5811fdc | ||
|
|
1f8f44b26c | ||
|
|
6729c38504 | ||
|
|
cf5d2c46f5 | ||
|
|
49e928273d | ||
|
|
00bbfbb20c | ||
|
|
ca120a3f04 | ||
|
|
e2b452c1f4 | ||
|
|
6695f76c5f | ||
|
|
bf25a637c8 |
6
doc/Jamfile.v2
Normal file → Executable file
6
doc/Jamfile.v2
Normal file → Executable file
@@ -22,3 +22,9 @@ for local b in $(bases)
|
||||
|
||||
alias htmls : $(bases) ;
|
||||
stage html : $(bases) ;
|
||||
|
||||
###############################################################################
|
||||
alias boostdoc ;
|
||||
explicit boostdoc ;
|
||||
alias boostrelease : htmls ;
|
||||
explicit boostrelease ;
|
||||
|
||||
@@ -37,7 +37,7 @@ can be deduced from their types.</p>
|
||||
</tbody>
|
||||
</table>
|
||||
<!-- @jam_prefix.append('''
|
||||
project test : requirements <include>. <source>/boost//headers ;''') -->
|
||||
project test : requirements <include>. <implicit-dependency>/boost//headers ;''') -->
|
||||
<!-- @example.prepend('''
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
@@ -727,7 +727,7 @@ worse—think of the kinds of errors you get from your STL
|
||||
implementation when you make a mistake).<a class="footnote-reference" href="#conceptcpp" id="id7"><sup>4</sup></a></li>
|
||||
<li>The problems with exposing such permissive function template
|
||||
signatures have been the subject of much discussion, especially
|
||||
in the presence of <a class="reference external" href="http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/lwg-defects.html#225">unqualified calls</a>. If all we want is to
|
||||
in the presence of <a class="reference external" href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#225">unqualified calls</a>. If all we want is to
|
||||
avoid unintentional argument-dependent lookup (ADL), we can
|
||||
isolate <tt class="docutils literal">depth_first_search</tt> in a namespace containing no
|
||||
types<a class="footnote-reference" href="#using" id="id8"><sup>6</sup></a>, but suppose we <em>want</em> it to found via ADL?</li>
|
||||
@@ -1632,7 +1632,7 @@ using boost::mpl::_;''') -->
|
||||
int main()
|
||||
{}''') -->
|
||||
<!-- @test('run', howmany='all') -->
|
||||
<p>Note that because of the <a class="reference external" href="http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2002/n1385.htm">forwarding problem</a>, <tt class="docutils literal"><span class="pre">parameter::parameters::operator()</span></tt>
|
||||
<p>Note that because of the <a class="reference external" href="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2002/n1385.htm">forwarding problem</a>, <tt class="docutils literal"><span class="pre">parameter::parameters::operator()</span></tt>
|
||||
can't accept non-const rvalues.</p>
|
||||
</div>
|
||||
<div class="section" id="extracting-parameter-types">
|
||||
|
||||
0
doc/html/rst.css
Normal file → Executable file
0
doc/html/rst.css
Normal file → Executable file
0
doc/html/vellipsis.gif
Normal file → Executable file
0
doc/html/vellipsis.gif
Normal file → Executable file
|
Before Width: | Height: | Size: 62 B After Width: | Height: | Size: 62 B |
@@ -30,7 +30,7 @@ __ ../../../../index.htm
|
||||
can be deduced from their types.
|
||||
|
||||
.. @jam_prefix.append('''
|
||||
project test : requirements <include>. <source>/boost//headers ;''')
|
||||
project test : requirements <include>. <implicit-dependency>/boost//headers ;''')
|
||||
|
||||
.. @example.prepend('''
|
||||
#include <boost/parameter.hpp>
|
||||
@@ -783,7 +783,7 @@ signatures.
|
||||
isolate ``depth_first_search`` in a namespace containing no
|
||||
types [#using]_, but suppose we *want* it to found via ADL?
|
||||
|
||||
__ http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/lwg-defects.html#225
|
||||
__ http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#225
|
||||
|
||||
It's usually a good idea to prevent functions from being considered
|
||||
for overload resolution when the passed argument types aren't
|
||||
@@ -1800,7 +1800,7 @@ its function call operator:
|
||||
Note that because of the `forwarding problem`_, ``parameter::parameters::operator()``
|
||||
can't accept non-const rvalues.
|
||||
|
||||
.. _`forwarding problem`: http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2002/n1385.htm
|
||||
.. _`forwarding problem`: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2002/n1385.htm
|
||||
|
||||
Extracting Parameter Types
|
||||
==========================
|
||||
|
||||
0
include/boost/parameter.hpp
Normal file → Executable file
0
include/boost/parameter.hpp
Normal file → Executable file
@@ -78,15 +78,11 @@ struct empty_arg_list
|
||||
};
|
||||
};
|
||||
|
||||
#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
// Terminator for has_key, indicating that the keyword is unique
|
||||
template <class KW>
|
||||
static no_tag has_key(KW*);
|
||||
#endif
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| (BOOST_WORKAROUND(__GNUC__, < 3)) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
|
||||
// The overload set technique doesn't work with these older
|
||||
// compilers, so they need some explicit handholding.
|
||||
@@ -150,11 +146,6 @@ struct empty_arg_list
|
||||
typedef arg_list_tag tag; // For dispatching to sequence intrinsics
|
||||
};
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
template<class KW>
|
||||
no_tag operator*(empty_arg_list, KW*);
|
||||
#endif
|
||||
|
||||
// Forward declaration for arg_list::operator,
|
||||
template <class KW, class T>
|
||||
struct tagged_argument;
|
||||
@@ -227,25 +218,17 @@ struct arg_list : Next
|
||||
};
|
||||
};
|
||||
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) && !BOOST_WORKAROUND(__GNUC__, == 2)
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
friend yes_tag operator*(arg_list, key_type*);
|
||||
# define BOOST_PARAMETER_CALL_HAS_KEY(next, key) (*(next*)0 * (key*)0)
|
||||
# else
|
||||
#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
// Overload for key_type, so the assert below will fire if the
|
||||
// same keyword is used again
|
||||
static yes_tag has_key(key_type*);
|
||||
using Next::has_key;
|
||||
|
||||
# define BOOST_PARAMETER_CALL_HAS_KEY(next, key) next::has_key((key*)0)
|
||||
# endif
|
||||
|
||||
BOOST_MPL_ASSERT_MSG(
|
||||
sizeof(BOOST_PARAMETER_CALL_HAS_KEY(Next,key_type)) == sizeof(no_tag)
|
||||
sizeof(Next::has_key((key_type*)0)) == sizeof(no_tag)
|
||||
, duplicate_keyword, (key_type)
|
||||
);
|
||||
|
||||
# undef BOOST_PARAMETER_CALL_HAS_KEY
|
||||
#endif
|
||||
//
|
||||
// Begin implementation of indexing operators for looking up
|
||||
@@ -266,9 +249,7 @@ struct arg_list : Next
|
||||
return arg.value ? arg.value.get() : arg.value.construct(d.value);
|
||||
}
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| BOOST_WORKAROUND(__GNUC__, < 3) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
// These older compilers don't support the overload set creation
|
||||
// idiom well, so we need to do all the return type calculation
|
||||
// for the compiler and dispatch through an outer function template
|
||||
@@ -358,6 +339,7 @@ struct arg_list : Next
|
||||
template <class Default>
|
||||
reference operator[](lazy_default<key_type, Default>) const
|
||||
{
|
||||
BOOST_MPL_ASSERT_NOT((holds_maybe));
|
||||
return arg.value;
|
||||
}
|
||||
|
||||
@@ -407,10 +389,6 @@ struct arg_list : Next
|
||||
typedef arg_list_tag tag; // For dispatching to sequence intrinsics
|
||||
};
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) // ETI workaround
|
||||
template <> struct arg_list<int,int> {};
|
||||
#endif
|
||||
|
||||
// MPL sequence support
|
||||
template <class ArgumentPack>
|
||||
struct arg_list_iterator
|
||||
|
||||
@@ -7,8 +7,7 @@
|
||||
|
||||
# include <boost/detail/workaround.hpp>
|
||||
|
||||
# if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \
|
||||
&& !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# include <boost/type_traits/add_reference.hpp>
|
||||
# include <boost/type_traits/remove_const.hpp>
|
||||
# endif
|
||||
@@ -17,8 +16,7 @@ namespace boost { namespace parameter { namespace aux {
|
||||
|
||||
struct use_default_tag {};
|
||||
|
||||
# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
|
||||
# define BOOST_PARAMETER_FUNCTION_CAST(value, predicate) value
|
||||
|
||||
|
||||
0
include/boost/parameter/aux_/overloads.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/overloads.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/parameter_requirements.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/parameter_requirements.hpp
Normal file → Executable file
@@ -18,96 +18,12 @@ namespace boost { namespace parameter { namespace aux {
|
||||
template <class UnaryFunctionPointer>
|
||||
struct unaryfunptr_arg_type;
|
||||
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
|
||||
template <class Arg>
|
||||
struct unaryfunptr_arg_type<void(*)(Arg)>
|
||||
{
|
||||
typedef Arg type;
|
||||
};
|
||||
|
||||
# else
|
||||
|
||||
// Use the "native typeof" bugfeatures of older versions of MSVC to
|
||||
// accomplish what we'd normally do with partial specialization. This
|
||||
// capability was discovered by Igor Chesnokov.
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, != 1300)
|
||||
|
||||
// This version applies to VC6.5 and VC7.1 (except that we can just
|
||||
// use partial specialization for the latter in this case).
|
||||
|
||||
// This gets used as a base class.
|
||||
template<typename Address>
|
||||
struct msvc_type_memory
|
||||
{
|
||||
// A nullary metafunction that will yield the Value type "stored"
|
||||
// at this Address.
|
||||
struct storage;
|
||||
};
|
||||
|
||||
template<typename Value, typename Address>
|
||||
struct msvc_store_type : msvc_type_memory<Address>
|
||||
{
|
||||
// VC++ somehow lets us define the base's nested storage
|
||||
// metafunction here, where we have the Value type we'd like to
|
||||
// "store" in it. Later we can come back to the base class and
|
||||
// extract the "stored type."
|
||||
typedef msvc_type_memory<Address> location;
|
||||
struct location::storage
|
||||
{
|
||||
typedef Value type;
|
||||
};
|
||||
};
|
||||
|
||||
# else
|
||||
|
||||
// This slightly more complicated version of the same thing is
|
||||
// required for msvc-7.0
|
||||
template<typename Address>
|
||||
struct msvc_type_memory
|
||||
{
|
||||
template<bool>
|
||||
struct storage_impl;
|
||||
|
||||
typedef storage_impl<true> storage;
|
||||
};
|
||||
|
||||
template<typename Value, typename Address>
|
||||
struct msvc_store_type : msvc_type_memory<Address>
|
||||
{
|
||||
// Rather than supplying a definition for the base class' nested
|
||||
// class, we specialize the base class' nested template
|
||||
template<>
|
||||
struct storage_impl<true>
|
||||
{
|
||||
typedef Value type;
|
||||
};
|
||||
};
|
||||
|
||||
# endif
|
||||
|
||||
// Function template argument deduction does many of the same things
|
||||
// as type matching during partial specialization, so we call a
|
||||
// function template to "store" T into the type memory addressed by
|
||||
// void(*)(T).
|
||||
template <class T>
|
||||
msvc_store_type<T,void(*)(T)>
|
||||
msvc_store_argument_type(void(*)(T));
|
||||
|
||||
template <class FunctionPointer>
|
||||
struct unaryfunptr_arg_type
|
||||
{
|
||||
// We don't want the function to be evaluated, just instantiated,
|
||||
// so protect it inside of sizeof.
|
||||
enum { dummy = sizeof(msvc_store_argument_type((FunctionPointer)0)) };
|
||||
|
||||
// Now pull the type out of the instantiated base class
|
||||
typedef typename msvc_type_memory<FunctionPointer>::storage::type type;
|
||||
};
|
||||
|
||||
# endif
|
||||
|
||||
template <>
|
||||
struct unaryfunptr_arg_type<void(*)(void)>
|
||||
{
|
||||
|
||||
0
include/boost/parameter/aux_/preprocessor/flatten.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/preprocessor/flatten.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/preprocessor/for_each.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/preprocessor/for_each.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/python/invoker_iterate.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/python/invoker_iterate.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/result_of0.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/result_of0.hpp
Normal file → Executable file
@@ -7,8 +7,7 @@
|
||||
|
||||
# include <boost/detail/workaround.hpp>
|
||||
|
||||
# if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) \
|
||||
&& !BOOST_WORKAROUND(__GNUC__, < 3)
|
||||
# if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# include <boost/mpl/insert.hpp>
|
||||
# include <boost/mpl/set/set0.hpp>
|
||||
# include <boost/mpl/has_key.hpp>
|
||||
|
||||
0
include/boost/parameter/aux_/tag.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/tag.hpp
Normal file → Executable file
@@ -120,13 +120,13 @@ struct tagged_argument : tagged_argument_base
|
||||
}
|
||||
# else
|
||||
template <class Default>
|
||||
reference operator[](default_<key_type,Default> const& x) const
|
||||
reference operator[](default_<key_type,Default> const& ) const
|
||||
{
|
||||
return value;
|
||||
}
|
||||
|
||||
template <class F>
|
||||
reference operator[](lazy_default<key_type,F> const& x) const
|
||||
reference operator[](lazy_default<key_type,F> const& ) const
|
||||
{
|
||||
return value;
|
||||
}
|
||||
|
||||
0
include/boost/parameter/aux_/template_keyword.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/template_keyword.hpp
Normal file → Executable file
@@ -44,12 +44,6 @@ struct is_cv_reference_wrapper
|
||||
value> type;
|
||||
};
|
||||
|
||||
#if BOOST_WORKAROUND(MSVC, == 1200)
|
||||
template <>
|
||||
struct is_cv_reference_wrapper<int>
|
||||
: mpl::false_ {};
|
||||
#endif
|
||||
|
||||
// Needed for unwrap_cv_reference below. T might be const, so
|
||||
// eval_if might fail because of deriving from T const on EDG.
|
||||
template <class T>
|
||||
|
||||
0
include/boost/parameter/aux_/void.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/void.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/yesno.hpp
Normal file → Executable file
0
include/boost/parameter/aux_/yesno.hpp
Normal file → Executable file
@@ -11,18 +11,13 @@
|
||||
# include <boost/parameter/aux_/void.hpp>
|
||||
# include <boost/type_traits/is_same.hpp>
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
# include <boost/mpl/eval_if.hpp>
|
||||
# endif
|
||||
|
||||
namespace boost { namespace parameter {
|
||||
|
||||
// A metafunction that, given an argument pack, returns the type of
|
||||
// the parameter identified by the given keyword. If no such
|
||||
// parameter has been specified, returns Default
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
template <class Parameters, class Keyword, class Default>
|
||||
struct binding0
|
||||
{
|
||||
@@ -40,14 +35,9 @@ struct binding0
|
||||
# endif
|
||||
|
||||
template <class Parameters, class Keyword, class Default = void_>
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
struct binding
|
||||
# else
|
||||
struct binding_eti
|
||||
# endif
|
||||
{
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
typedef typename mpl::eval_if<
|
||||
mpl::is_placeholder<Parameters>
|
||||
, mpl::identity<int>
|
||||
@@ -66,24 +56,8 @@ struct binding_eti
|
||||
));
|
||||
# endif
|
||||
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
BOOST_MPL_AUX_LAMBDA_SUPPORT(3,binding,(Parameters,Keyword,Default))
|
||||
# endif
|
||||
};
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
template <class Parameters, class Keyword, class Default = void_>
|
||||
struct binding
|
||||
{
|
||||
typedef typename mpl::eval_if<
|
||||
is_same<Parameters, int>
|
||||
, mpl::identity<int>
|
||||
, binding_eti<Parameters, Keyword, Default>
|
||||
>::type type;
|
||||
|
||||
BOOST_MPL_AUX_LAMBDA_SUPPORT(3,binding,(Parameters,Keyword,Default))
|
||||
};
|
||||
# endif
|
||||
|
||||
// A metafunction that, given an argument pack, returns the type of
|
||||
// the parameter identified by the given keyword. If no such
|
||||
|
||||
@@ -52,7 +52,6 @@ struct keyword
|
||||
return aux::lazy_default<Tag, Default>(default_);
|
||||
}
|
||||
|
||||
#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) // avoid partial ordering bugs
|
||||
template <class T>
|
||||
typename aux::tag<Tag, T const>::type const
|
||||
operator=(T const& x) const
|
||||
@@ -60,15 +59,10 @@ struct keyword
|
||||
typedef typename aux::tag<Tag, T const>::type result;
|
||||
return result(x);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) // avoid partial ordering bugs
|
||||
template <class Default>
|
||||
aux::default_<Tag, const Default>
|
||||
operator|(const Default& default_) const
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
|
||||
volatile
|
||||
#endif
|
||||
{
|
||||
return aux::default_<Tag, const Default>(default_);
|
||||
}
|
||||
@@ -76,13 +70,9 @@ struct keyword
|
||||
template <class Default>
|
||||
aux::lazy_default<Tag, Default>
|
||||
operator||(Default const& default_) const
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
|
||||
volatile
|
||||
#endif
|
||||
{
|
||||
return aux::lazy_default<Tag, Default>(default_);
|
||||
}
|
||||
#endif
|
||||
|
||||
public: // Insurance against ODR violations
|
||||
|
||||
@@ -109,24 +99,6 @@ keyword<Tag> const keyword<Tag>::instance = {};
|
||||
// reference in an anonymous namespace to a singleton instance of that
|
||||
// type.
|
||||
|
||||
#if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
|
||||
# define BOOST_PARAMETER_KEYWORD(tag_namespace,name) \
|
||||
namespace tag_namespace \
|
||||
{ \
|
||||
struct name \
|
||||
{ \
|
||||
static char const* keyword_name() \
|
||||
{ \
|
||||
return #name; \
|
||||
} \
|
||||
}; \
|
||||
} \
|
||||
static ::boost::parameter::keyword<tag_namespace::name> const& name \
|
||||
= ::boost::parameter::keyword<tag_namespace::name>::instance;
|
||||
|
||||
#else
|
||||
|
||||
#define BOOST_PARAMETER_KEYWORD(tag_namespace,name) \
|
||||
namespace tag_namespace \
|
||||
{ \
|
||||
@@ -144,8 +116,6 @@ keyword<Tag> const keyword<Tag>::instance = {};
|
||||
= ::boost::parameter::keyword<tag_namespace::name>::instance;\
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
}} // namespace boost::parameter
|
||||
|
||||
#endif // KEYWORD_050328_HPP
|
||||
|
||||
0
include/boost/parameter/match.hpp
Normal file → Executable file
0
include/boost/parameter/match.hpp
Normal file → Executable file
@@ -16,7 +16,6 @@
|
||||
# include <boost/mpl/placeholders.hpp>
|
||||
|
||||
# if !defined(BOOST_NO_SFINAE) \
|
||||
&& !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \
|
||||
&& !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x592))
|
||||
|
||||
# include <boost/utility/enable_if.hpp>
|
||||
@@ -75,19 +74,6 @@ struct lambda<
|
||||
# define BOOST_PARAMETER_IS_BINARY(x) BOOST_PP_IS_BINARY(x)
|
||||
# endif
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
# define BOOST_PARAMETER_NAME_OBJECT(tag, name) \
|
||||
static ::boost::parameter::keyword<tag> const& name \
|
||||
= ::boost::parameter::keyword<tag>::instance;
|
||||
# else
|
||||
# define BOOST_PARAMETER_NAME_OBJECT(tag, name) \
|
||||
namespace \
|
||||
{ \
|
||||
::boost::parameter::keyword<tag> const& name \
|
||||
= ::boost::parameter::keyword<tag>::instance; \
|
||||
}
|
||||
# endif
|
||||
|
||||
# define BOOST_PARAMETER_BASIC_NAME(tag_namespace, tag, name) \
|
||||
namespace tag_namespace \
|
||||
{ \
|
||||
@@ -107,7 +93,11 @@ struct lambda<
|
||||
> _1; \
|
||||
}; \
|
||||
} \
|
||||
BOOST_PARAMETER_NAME_OBJECT(tag_namespace::tag, name)
|
||||
namespace \
|
||||
{ \
|
||||
::boost::parameter::keyword<tag_namespace::tag> const& name \
|
||||
= ::boost::parameter::keyword<tag_namespace::tag>::instance; \
|
||||
}
|
||||
|
||||
# define BOOST_PARAMETER_COMPLEX_NAME_TUPLE1(tag,namespace) \
|
||||
(tag, namespace), ~
|
||||
|
||||
0
include/boost/parameter/parameters.hpp
Normal file → Executable file
0
include/boost/parameter/parameters.hpp
Normal file → Executable file
@@ -37,10 +37,6 @@
|
||||
# include <boost/mpl/always.hpp>
|
||||
# include <boost/mpl/apply_wrap.hpp>
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
# include <boost/type.hpp>
|
||||
# endif
|
||||
|
||||
namespace boost { namespace parameter { namespace aux {
|
||||
|
||||
# if ! defined(BOOST_NO_SFINAE) && ! BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x592))
|
||||
@@ -102,41 +98,6 @@ struct match
|
||||
{};
|
||||
# endif
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
|
||||
|
||||
// Function template argument deduction does many of the same things
|
||||
// as type matching during partial specialization, so we call a
|
||||
// function template to "store" T into the type memory addressed by
|
||||
// void(*)(T).
|
||||
template <class T>
|
||||
msvc_store_type<T,void*(*)(void**(T))>
|
||||
msvc_store_predicate_type(void*(*)(void**(T)));
|
||||
|
||||
template <class T>
|
||||
msvc_store_type<boost::is_convertible<mpl::_,T>,void*(*)(void*(T))>
|
||||
msvc_store_predicate_type(void*(*)(void*(T)));
|
||||
|
||||
template <class FunctionType>
|
||||
struct unwrap_predicate
|
||||
{
|
||||
static FunctionType f;
|
||||
|
||||
// We don't want the function to be evaluated, just instantiated,
|
||||
// so protect it inside of sizeof.
|
||||
enum { dummy = sizeof(msvc_store_predicate_type(f)) };
|
||||
|
||||
// Now pull the type out of the instantiated base class
|
||||
typedef typename msvc_type_memory<FunctionType>::storage::type type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct unwrap_predicate<void*(*)(void**)>
|
||||
{
|
||||
typedef mpl::always<mpl::true_> type;
|
||||
};
|
||||
|
||||
# endif
|
||||
|
||||
# undef false_
|
||||
|
||||
template <
|
||||
@@ -158,7 +119,6 @@ struct argument_pack
|
||||
typedef typename mpl::first<result>::type type;
|
||||
};
|
||||
|
||||
# if 1 //BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
// Works around VC6 problem where it won't accept rvalues.
|
||||
template <class T>
|
||||
T& as_lvalue(T& value, long)
|
||||
@@ -171,11 +131,9 @@ T const& as_lvalue(T const& value, int)
|
||||
{
|
||||
return value;
|
||||
}
|
||||
# endif
|
||||
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
|
||||
template <class Predicate, class T, class Args>
|
||||
struct apply_predicate
|
||||
@@ -502,13 +460,7 @@ struct funptr_predicate<void**>
|
||||
# define BOOST_PARAMETER_FUNCTION_PARAMETERS_QUALIFIER_deduced_required(tag) \
|
||||
required<boost::parameter::deduced<tag>
|
||||
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, < 1300) && !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
|
||||
# define BOOST_PARAMETER_PREDICATE_TYPE(p) void*(*) (void* p)
|
||||
# else
|
||||
# define BOOST_PARAMETER_PREDICATE_TYPE(p) void p
|
||||
# endif
|
||||
# if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
|
||||
# define BOOST_PARAMETER_FUNCTION_PARAMETERS_M(r,tag_namespace,i,elem) \
|
||||
BOOST_PP_COMMA_IF(i) \
|
||||
@@ -521,24 +473,9 @@ struct funptr_predicate<void**>
|
||||
) \
|
||||
) \
|
||||
, typename boost::parameter::aux::unwrap_predicate< \
|
||||
BOOST_PARAMETER_PREDICATE_TYPE(BOOST_PARAMETER_FN_ARG_PRED(elem)) \
|
||||
void BOOST_PARAMETER_FN_ARG_PRED(elem) \
|
||||
>::type \
|
||||
>
|
||||
# elif BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
# define BOOST_PARAMETER_FUNCTION_PARAMETERS_M(r,tag_namespace,i,elem) \
|
||||
BOOST_PP_COMMA_IF(i) \
|
||||
boost::parameter::BOOST_PP_CAT( \
|
||||
BOOST_PARAMETER_FUNCTION_PARAMETERS_QUALIFIER_ \
|
||||
, BOOST_PARAMETER_FN_ARG_QUALIFIER(elem) \
|
||||
)( \
|
||||
tag_namespace::BOOST_PARAMETER_FUNCTION_KEYWORD( \
|
||||
BOOST_PARAMETER_FN_ARG_KEYWORD(elem) \
|
||||
) \
|
||||
) \
|
||||
, boost::parameter::aux::funptr_predicate< \
|
||||
void* BOOST_PARAMETER_FN_ARG_PRED(elem) \
|
||||
> \
|
||||
>
|
||||
# elif BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# define BOOST_PARAMETER_FUNCTION_PARAMETERS_M(r,tag_namespace,i,elem) \
|
||||
BOOST_PP_COMMA_IF(i) \
|
||||
@@ -583,21 +520,6 @@ struct funptr_predicate<void**>
|
||||
typedef typename BOOST_PARAMETER_PARENTHESIZED_TYPE(result) type; \
|
||||
};
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
|
||||
# define BOOST_PARAMETER_FUNCTION_RESULT(result, name, args) \
|
||||
BOOST_PARAMETER_FUNCTION_RESULT_(result, name, args) \
|
||||
template <> \
|
||||
struct BOOST_PARAMETER_FUNCTION_RESULT_NAME(name)<int> \
|
||||
{ typedef int type; };
|
||||
|
||||
# else
|
||||
|
||||
# define BOOST_PARAMETER_FUNCTION_RESULT(result, name, args) \
|
||||
BOOST_PARAMETER_FUNCTION_RESULT_(result, name, args)
|
||||
|
||||
# endif
|
||||
|
||||
// Defines implementation function
|
||||
# define BOOST_PARAMETER_FUNCTION_IMPL_HEAD(name) \
|
||||
template <class Args> \
|
||||
@@ -896,7 +818,7 @@ struct funptr_predicate<void**>
|
||||
BOOST_PARAMETER_MEMBER_FUNCTION_STATIC(name) \
|
||||
ResultType BOOST_PARAMETER_FUNCTION_DEFAULT_NAME(name)( \
|
||||
ResultType(*)() \
|
||||
, Args const& args \
|
||||
, Args const& \
|
||||
, int \
|
||||
BOOST_PARAMETER_FUNCTION_DEFAULT_ARGUMENTS( \
|
||||
BOOST_PARAMETER_FUNCTION_DEFAULT_FUNCTION_ARG \
|
||||
@@ -915,7 +837,7 @@ struct funptr_predicate<void**>
|
||||
|
||||
// Defines the result metafunction and the parameters specialization.
|
||||
# define BOOST_PARAMETER_FUNCTION_HEAD(result, name, tag_namespace, args) \
|
||||
BOOST_PARAMETER_FUNCTION_RESULT(result, name, args) \
|
||||
BOOST_PARAMETER_FUNCTION_RESULT_(result, name, args) \
|
||||
\
|
||||
BOOST_PARAMETER_FUNCTION_PARAMETERS(tag_namespace, name, args) \
|
||||
BOOST_PARAMETER_FUNCTION_PARAMETERS_NAME(name); \
|
||||
@@ -1021,18 +943,6 @@ struct funptr_predicate<void**>
|
||||
BOOST_PP_COMMA_IF(i) elem& BOOST_PP_CAT(a, i)
|
||||
/**/
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
|
||||
|
||||
// Older MSVC can't do what's necessary to handle commas in base names; just
|
||||
// use a typedef instead if you have a base name that contains commas.
|
||||
# define BOOST_PARAMETER_PARENTHESIZED_BASE(x) BOOST_PP_SEQ_HEAD(x)
|
||||
|
||||
# else
|
||||
|
||||
# define BOOST_PARAMETER_PARENTHESIZED_BASE(x) BOOST_PARAMETER_PARENTHESIZED_TYPE(x)
|
||||
|
||||
# endif
|
||||
|
||||
# define BOOST_PARAMETER_FUNCTION_FWD_CONSTRUCTOR00(z, n, r, data, elem) \
|
||||
BOOST_PP_IF( \
|
||||
n \
|
||||
@@ -1057,7 +967,7 @@ struct funptr_predicate<void**>
|
||||
, n \
|
||||
) \
|
||||
) \
|
||||
: BOOST_PARAMETER_PARENTHESIZED_BASE(BOOST_PP_TUPLE_ELEM(6,3,data)) ( \
|
||||
: BOOST_PARAMETER_PARENTHESIZED_TYPE(BOOST_PP_TUPLE_ELEM(6,3,data)) ( \
|
||||
BOOST_PP_CAT(constructor_parameters, __LINE__)()( \
|
||||
BOOST_PP_ENUM_PARAMS_Z(z, n, a) \
|
||||
) \
|
||||
@@ -1148,18 +1058,7 @@ struct funptr_predicate<void**>
|
||||
, (const ParameterArgumentType ## i)(ParameterArgumentType ## i) \
|
||||
, (const ParameterArgumentType ## i) \
|
||||
))
|
||||
// MSVC6.5 lets us bind rvalues to T&.
|
||||
# elif BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
# define BOOST_PARAMETER_FUNCTION_FWD_COMBINATION(r, _, i, elem) \
|
||||
(BOOST_PP_IF( \
|
||||
BOOST_PARAMETER_FUNCTION_IS_KEYWORD_QUALIFIER( \
|
||||
BOOST_PARAMETER_FN_ARG_NAME(elem) \
|
||||
) \
|
||||
, (ParameterArgumentType ## i) \
|
||||
, (const ParameterArgumentType ## i) \
|
||||
))
|
||||
// No partial ordering. This feature doesn't work.
|
||||
// This is exactly the same as for VC6.5, but we might change it later.
|
||||
# else
|
||||
# define BOOST_PARAMETER_FUNCTION_FWD_COMBINATION(r, _, i, elem) \
|
||||
(BOOST_PP_IF( \
|
||||
|
||||
0
include/boost/parameter/python.hpp
Normal file → Executable file
0
include/boost/parameter/python.hpp
Normal file → Executable file
@@ -12,18 +12,13 @@
|
||||
# include <boost/parameter/aux_/void.hpp>
|
||||
# include <boost/type_traits/is_same.hpp>
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
# include <boost/mpl/eval_if.hpp>
|
||||
# endif
|
||||
|
||||
namespace boost { namespace parameter {
|
||||
|
||||
// A metafunction that, given an argument pack, returns the type of
|
||||
// the parameter identified by the given keyword. If no such
|
||||
// parameter has been specified, returns Default
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
template <class Parameters, class Keyword, class Default>
|
||||
struct value_type0
|
||||
{
|
||||
@@ -41,14 +36,9 @@ struct value_type0
|
||||
# endif
|
||||
|
||||
template <class Parameters, class Keyword, class Default = void_>
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
struct value_type
|
||||
# else
|
||||
struct value_type_eti
|
||||
# endif
|
||||
{
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) \
|
||||
|| BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
# if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
|
||||
typedef typename mpl::eval_if<
|
||||
mpl::is_placeholder<Parameters>
|
||||
, mpl::identity<int>
|
||||
@@ -67,24 +57,8 @@ struct value_type_eti
|
||||
));
|
||||
# endif
|
||||
|
||||
# if !BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
BOOST_MPL_AUX_LAMBDA_SUPPORT(3,value_type,(Parameters,Keyword,Default))
|
||||
# endif
|
||||
};
|
||||
|
||||
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
|
||||
template <class Parameters, class Keyword, class Default = void_>
|
||||
struct value_type
|
||||
{
|
||||
typedef typename mpl::eval_if<
|
||||
is_same<Parameters, int>
|
||||
, mpl::identity<int>
|
||||
, value_type_eti<Parameters, Keyword, Default>
|
||||
>::type type;
|
||||
|
||||
BOOST_MPL_AUX_LAMBDA_SUPPORT(3,value_type,(Parameters,Keyword,Default))
|
||||
};
|
||||
# endif
|
||||
|
||||
// A metafunction that, given an argument pack, returns the type of
|
||||
// the parameter identified by the given keyword. If no such
|
||||
|
||||
0
index.html
Normal file → Executable file
0
index.html
Normal file → Executable file
17
meta/libraries.json
Normal file
17
meta/libraries.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"key": "parameter",
|
||||
"name": "Parameter",
|
||||
"authors": [
|
||||
"David Abrahams",
|
||||
"Daniel Wallin"
|
||||
],
|
||||
"description": "Boost.Parameter Library - Write functions that accept arguments by name.",
|
||||
"category": [
|
||||
"Emulation",
|
||||
"Programming"
|
||||
],
|
||||
"maintainers": [
|
||||
"David Abrahams <dave -at- boost-consulting.com>",
|
||||
"Daniel Wallin <daniel -at- boostpro.com>"
|
||||
]
|
||||
}
|
||||
0
test/basics.cpp
Normal file → Executable file
0
test/basics.cpp
Normal file → Executable file
0
test/basics.hpp
Normal file → Executable file
0
test/basics.hpp
Normal file → Executable file
0
test/deduced.cpp
Normal file → Executable file
0
test/deduced.cpp
Normal file → Executable file
0
test/deduced.hpp
Normal file → Executable file
0
test/deduced.hpp
Normal file → Executable file
0
test/deduced_dependent_predicate.cpp
Normal file → Executable file
0
test/deduced_dependent_predicate.cpp
Normal file → Executable file
0
test/deduced_unmatched_arg.cpp
Normal file → Executable file
0
test/deduced_unmatched_arg.cpp
Normal file → Executable file
0
test/duplicates.cpp
Normal file → Executable file
0
test/duplicates.cpp
Normal file → Executable file
0
test/earwicker.cpp
Normal file → Executable file
0
test/earwicker.cpp
Normal file → Executable file
0
test/efficiency.cpp
Normal file → Executable file
0
test/efficiency.cpp
Normal file → Executable file
@@ -1,8 +1,6 @@
|
||||
|
||||
#line 1744 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 1733 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(index)
|
||||
|
||||
template <class ArgumentPack>
|
||||
@@ -14,7 +12,6 @@ int print_index(ArgumentPack const& args)
|
||||
|
||||
int x = print_index(_index = 3); // prints "index = 3"
|
||||
|
||||
#line 1752 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
|
||||
template <class ArgumentPack>
|
||||
@@ -27,13 +24,11 @@ int print_name_and_index(ArgumentPack const& args)
|
||||
int y = print_name_and_index((_index = 3, _name = "jones"));
|
||||
|
||||
|
||||
#line 1787 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace parameter = boost::parameter;
|
||||
using parameter::required;
|
||||
using parameter::optional;
|
||||
using boost::is_convertible;
|
||||
using boost::mpl::_;
|
||||
#line 1773 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
parameter::parameters<
|
||||
required<tag::name, is_convertible<_,char const*> >
|
||||
, optional<tag::index, is_convertible<_,int> >
|
||||
@@ -47,7 +42,6 @@ int z0 = print_name_and_index( spec(sam, twelve) );
|
||||
int z1 = print_name_and_index(
|
||||
spec(_index=12, _name="sam")
|
||||
);
|
||||
#line 1794 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main()
|
||||
{}
|
||||
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
#line 1387 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#line 1373 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
template <
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 1062 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
@@ -31,7 +30,6 @@ default_call_policies some_policies;
|
||||
|
||||
void f()
|
||||
{}
|
||||
#line 1029 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace mpl = boost::mpl;
|
||||
|
||||
BOOST_PARAMETER_FUNCTION(
|
||||
@@ -64,17 +62,13 @@ BOOST_PARAMETER_FUNCTION(
|
||||
}
|
||||
|
||||
|
||||
#line 1111 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main()
|
||||
{
|
||||
#line 1108 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
def("f", &f, some_policies, "Documentation for f");
|
||||
def("f", &f, "Documentation for f", some_policies);
|
||||
|
||||
#line 1121 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
def(
|
||||
"f", &f
|
||||
, _policies = some_policies, "Documentation for f");
|
||||
#line 1124 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
|
||||
#line 1557 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <boost/mpl/is_sequence.hpp>
|
||||
#include <boost/noncopyable.hpp>
|
||||
#include <memory>
|
||||
#include <boost/config.hpp>
|
||||
|
||||
using namespace boost::parameter;
|
||||
using boost::mpl::_;
|
||||
@@ -16,7 +16,6 @@ BOOST_PARAMETER_TEMPLATE_KEYWORD(held_type)
|
||||
BOOST_PARAMETER_TEMPLATE_KEYWORD(copyable)
|
||||
|
||||
}}
|
||||
#line 1546 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
namespace detail { struct bases_base {}; }
|
||||
@@ -28,10 +27,8 @@ struct bases : detail::bases_base
|
||||
}}
|
||||
|
||||
|
||||
#line 1600 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/type_traits/is_class.hpp>
|
||||
namespace boost { namespace python {
|
||||
#line 1578 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
typedef parameter::parameters<
|
||||
required<tag::class_type, is_class<_> >
|
||||
|
||||
@@ -53,7 +50,6 @@ typedef parameter::parameters<
|
||||
, parameter::optional<deduced<tag::copyable>, is_same<noncopyable,_> >
|
||||
|
||||
> class_signature;
|
||||
#line 1604 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
template <
|
||||
class A0
|
||||
, class A1 = parameter::void_
|
||||
@@ -85,16 +81,22 @@ struct class_
|
||||
|
||||
|
||||
|
||||
#line 1644 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
struct B {};
|
||||
struct D {};
|
||||
|
||||
using boost::python::bases;
|
||||
#line 1640 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
typedef boost::python::class_<B, boost::noncopyable> c1;
|
||||
|
||||
#if defined(BOOST_NO_CXX11_SMART_PTR)
|
||||
|
||||
typedef boost::python::class_<D, std::auto_ptr<D>, bases<B> > c2;
|
||||
#line 1650 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
|
||||
#else
|
||||
|
||||
typedef boost::python::class_<D, std::unique_ptr<D>, bases<B> > c2;
|
||||
|
||||
#endif
|
||||
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::class_type, B>));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::base_list, bases<> >));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::held_type, B>));
|
||||
@@ -104,8 +106,19 @@ BOOST_MPL_ASSERT((
|
||||
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::class_type, D>));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::base_list, bases<B> >));
|
||||
|
||||
#if defined(BOOST_NO_CXX11_SMART_PTR)
|
||||
|
||||
BOOST_MPL_ASSERT((
|
||||
boost::is_same<c2::held_type, std::auto_ptr<D> >
|
||||
));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::copyable, void>));
|
||||
|
||||
#else
|
||||
|
||||
BOOST_MPL_ASSERT((
|
||||
boost::is_same<c2::held_type, std::unique_ptr<D> >
|
||||
));
|
||||
|
||||
#endif
|
||||
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::copyable, void>));
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 730 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
|
||||
@@ -8,7 +7,6 @@ BOOST_PARAMETER_NAME(visitor)
|
||||
BOOST_PARAMETER_NAME(root_vertex)
|
||||
BOOST_PARAMETER_NAME(index_map)
|
||||
BOOST_PARAMETER_NAME(color_map)
|
||||
#line 702 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/graph/depth_first_search.hpp> // for dfs_visitor
|
||||
|
||||
BOOST_PARAMETER_FUNCTION(
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
#line 397 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter/name.hpp>
|
||||
|
||||
namespace graphs
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
#line 424 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter/keyword.hpp>
|
||||
#line 413 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace graphs
|
||||
{
|
||||
namespace tag { struct graph; } // keyword tag type
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
|
||||
#line 1415 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <boost/mpl/is_sequence.hpp>
|
||||
#include <boost/noncopyable.hpp>
|
||||
#include <boost/type_traits/is_class.hpp>
|
||||
#include <memory>
|
||||
#include <boost/config.hpp>
|
||||
|
||||
using namespace boost::parameter;
|
||||
|
||||
@@ -20,7 +20,6 @@ struct bases
|
||||
{};
|
||||
|
||||
}}
|
||||
#line 1402 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
using boost::mpl::_;
|
||||
@@ -34,7 +33,6 @@ typedef parameter::parameters<
|
||||
|
||||
}}
|
||||
|
||||
#line 1454 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
template <
|
||||
@@ -67,7 +65,6 @@ struct class_
|
||||
}}
|
||||
|
||||
|
||||
#line 1 "None"
|
||||
using boost::python::class_type;
|
||||
using boost::python::copyable;
|
||||
using boost::python::held_type;
|
||||
@@ -76,16 +73,24 @@ using boost::python::bases;
|
||||
|
||||
struct B {};
|
||||
struct D {};
|
||||
#line 1495 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
typedef boost::python::class_<
|
||||
class_type<B>, copyable<boost::noncopyable>
|
||||
> c1;
|
||||
|
||||
typedef boost::python::class_<
|
||||
|
||||
#if defined(BOOST_NO_CXX11_SMART_PTR)
|
||||
|
||||
D, held_type<std::auto_ptr<D> >, base_list<bases<B> >
|
||||
|
||||
#else
|
||||
|
||||
D, held_type<std::unique_ptr<D> >, base_list<bases<B> >
|
||||
|
||||
#endif
|
||||
|
||||
> c2;
|
||||
|
||||
#line 1515 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::class_type, B>));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::base_list, bases<> >));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c1::held_type, B>));
|
||||
@@ -95,7 +100,19 @@ BOOST_MPL_ASSERT((
|
||||
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::class_type, D>));
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::base_list, bases<B> >));
|
||||
|
||||
#if defined(BOOST_NO_CXX11_SMART_PTR)
|
||||
|
||||
BOOST_MPL_ASSERT((
|
||||
boost::is_same<c2::held_type, std::auto_ptr<D> >
|
||||
));
|
||||
|
||||
#else
|
||||
|
||||
BOOST_MPL_ASSERT((
|
||||
boost::is_same<c2::held_type, std::unique_ptr<D> >
|
||||
));
|
||||
|
||||
#endif
|
||||
|
||||
BOOST_MPL_ASSERT((boost::is_same<c2::copyable, void>));
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
|
||||
#line 1830 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <cassert>
|
||||
#line 1813 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
BOOST_PARAMETER_NAME(index)
|
||||
|
||||
@@ -19,7 +17,6 @@ int deduce_arg_types(ArgumentPack const& args)
|
||||
{
|
||||
return deduce_arg_types_impl(args[_name], args[_index|42]);
|
||||
}
|
||||
#line 1834 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int a1 = deduce_arg_types((_name = "foo"));
|
||||
int a2 = deduce_arg_types((_name = "foo", _index = 3));
|
||||
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
|
||||
#line 1863 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <boost/type_traits/remove_reference.hpp>
|
||||
#include <cassert>
|
||||
|
||||
namespace parameter = boost::parameter;
|
||||
#line 1852 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(index)
|
||||
|
||||
template <class ArgumentPack>
|
||||
@@ -16,7 +14,6 @@ twice_index(ArgumentPack const& args)
|
||||
}
|
||||
|
||||
int six = twice_index(_index = 3);
|
||||
#line 1871 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main()
|
||||
{
|
||||
assert(six == 6);
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
#line 1703 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#line 1693 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME((pass_foo, keywords) foo)
|
||||
|
||||
BOOST_PARAMETER_FUNCTION(
|
||||
@@ -12,7 +10,6 @@ BOOST_PARAMETER_FUNCTION(
|
||||
}
|
||||
|
||||
int x = f(pass_foo = 41);
|
||||
#line 1704 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main()
|
||||
{}
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 620 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
namespace boost
|
||||
@@ -20,7 +19,6 @@ BOOST_PARAMETER_NAME(color_map)
|
||||
|
||||
BOOST_PARAMETER_FUNCTION((void), f, tag,
|
||||
(required (graph, *))
|
||||
#line 612 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
(optional
|
||||
(visitor, *, boost::dfs_visitor<>())
|
||||
(root_vertex, *, *vertices(graph).first)
|
||||
@@ -28,6 +26,5 @@ BOOST_PARAMETER_FUNCTION((void), f, tag,
|
||||
(in_out(color_map), *,
|
||||
default_color_map(num_vertices(graph), index_map) )
|
||||
)
|
||||
#line 642 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
) {}
|
||||
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#line 274 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter/keyword.hpp>
|
||||
#line 283 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
using boost::parameter::keyword;
|
||||
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
|
||||
#line 1911 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <string>
|
||||
|
||||
namespace parameter = boost::parameter;
|
||||
#line 1894 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(s1)
|
||||
BOOST_PARAMETER_NAME(s2)
|
||||
BOOST_PARAMETER_NAME(s3)
|
||||
@@ -21,7 +19,6 @@ std::string f(ArgumentPack const& args)
|
||||
}
|
||||
|
||||
std::string x = f((_s1="hello,", _s2=" world", _s3="hi world"));
|
||||
#line 1917 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main()
|
||||
{}
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 1943 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/bind.hpp>
|
||||
#include <boost/ref.hpp>
|
||||
#include <boost/parameter.hpp>
|
||||
@@ -17,12 +16,10 @@ std::string f(ArgumentPack const& args)
|
||||
{
|
||||
std::string const& s1 = args[_s1];
|
||||
std::string const& s2 = args[_s2];
|
||||
#line 1938 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
typename parameter::binding<
|
||||
ArgumentPack, tag::s3, std::string
|
||||
>::type s3 = args[_s3
|
||||
|| boost::bind(std::plus<std::string>(), boost::ref(s1), boost::ref(s2)) ];
|
||||
#line 1962 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
return s3;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
|
||||
#line 2082 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#line 2085 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 2071 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace lib
|
||||
{
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
@@ -18,8 +15,6 @@ namespace lib
|
||||
return index;
|
||||
}
|
||||
}
|
||||
#line 2098 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int x = lib::f(lib::_name = "jill", lib::_index = 1);
|
||||
#line 2102 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main() {}
|
||||
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
|
||||
#line 2100 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#line 2085 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 2071 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace lib
|
||||
{
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
@@ -18,11 +15,9 @@ namespace lib
|
||||
return index;
|
||||
}
|
||||
}
|
||||
#line 2111 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
using lib::_name;
|
||||
using lib::_index;
|
||||
|
||||
int x = lib::f(_name = "jill", _index = 1);
|
||||
#line 2120 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main() {}
|
||||
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
|
||||
#line 2114 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#line 2085 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 2071 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace lib
|
||||
{
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
@@ -18,9 +15,7 @@ namespace lib
|
||||
return index;
|
||||
}
|
||||
}
|
||||
#line 2128 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
using namespace lib;
|
||||
int x = f(_name = "jill", _index = 3);
|
||||
#line 2134 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main() {}
|
||||
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
|
||||
#line 2161 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 2143 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace lib
|
||||
{
|
||||
namespace keywords
|
||||
@@ -21,9 +19,7 @@ namespace lib
|
||||
}
|
||||
}
|
||||
|
||||
#line 2170 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
using namespace lib::keywords;
|
||||
int y = lib::f(_name = "bob", _index = 2);
|
||||
#line 2172 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main() {}
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 571 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
namespace boost
|
||||
@@ -19,13 +18,11 @@ BOOST_PARAMETER_NAME(color_map)
|
||||
|
||||
BOOST_PARAMETER_FUNCTION((void), f, tag,
|
||||
(required (graph, *))
|
||||
#line 563 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
(optional (visitor, *, boost::dfs_visitor<>())
|
||||
(root_vertex, *, *vertices(graph).first)
|
||||
(index_map, *, get(boost::vertex_index,graph))
|
||||
(in_out(color_map), *,
|
||||
default_color_map(num_vertices(graph), index_map) )
|
||||
)
|
||||
#line 592 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
) {}
|
||||
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
|
||||
#line 1248 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
#line 1234 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(name)
|
||||
BOOST_PARAMETER_NAME(index)
|
||||
|
||||
@@ -17,7 +15,6 @@ struct myclass_impl
|
||||
}
|
||||
};
|
||||
|
||||
#line 1261 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
struct myclass : myclass_impl
|
||||
{
|
||||
BOOST_PARAMETER_CONSTRUCTOR(
|
||||
@@ -26,12 +23,9 @@ struct myclass : myclass_impl
|
||||
};
|
||||
|
||||
|
||||
#line 1275 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
int main() {
|
||||
#line 1272 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
myclass x("bob", 3); // positional
|
||||
myclass y(_index = 12, _name = "sally"); // named
|
||||
myclass z("june"); // positional/defaulted
|
||||
#line 1275 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
}
|
||||
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
|
||||
#line 1154 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
using namespace boost::parameter;
|
||||
#line 1142 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(arg1)
|
||||
BOOST_PARAMETER_NAME(arg2)
|
||||
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
|
||||
#line 1177 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
BOOST_PARAMETER_NAME(arg1)
|
||||
BOOST_PARAMETER_NAME(arg2)
|
||||
using namespace boost::parameter;
|
||||
#line 1166 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
struct callable2
|
||||
{
|
||||
BOOST_PARAMETER_CONST_MEMBER_FUNCTION(
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 935 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <boost/graph/adjacency_list.hpp>
|
||||
#include <boost/graph/depth_first_search.hpp>
|
||||
@@ -11,7 +10,6 @@ BOOST_PARAMETER_NAME((_index_map, graphs) index_map)
|
||||
BOOST_PARAMETER_NAME((_color_map, graphs) color_map)
|
||||
|
||||
using boost::mpl::_;
|
||||
#line 859 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
// We first need to define a few metafunction that we use in the
|
||||
// predicates below.
|
||||
|
||||
@@ -87,7 +85,6 @@ BOOST_PARAMETER_FUNCTION(
|
||||
, default_color_map(num_vertices(graph), index_map) )
|
||||
)
|
||||
)
|
||||
#line 949 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
{}
|
||||
|
||||
int main()
|
||||
@@ -100,7 +97,7 @@ int main()
|
||||
E(w,z), E(z, z)};
|
||||
G g(edges, edges + sizeof(edges) / sizeof(E), N);
|
||||
|
||||
depth_first_search(g);
|
||||
depth_first_search(g, _root_vertex = (int)x);
|
||||
::depth_first_search(g);
|
||||
::depth_first_search(g, _root_vertex = (int)x);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
|
||||
#line 540 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
BOOST_PARAMETER_NAME(graph)
|
||||
|
||||
BOOST_PARAMETER_FUNCTION((void), f, tag,
|
||||
#line 531 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
(required (graph, *) )
|
||||
#line 547 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
) {}
|
||||
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
|
||||
#line 1206 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#include <iostream>
|
||||
using namespace boost::parameter;
|
||||
#line 1195 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
BOOST_PARAMETER_NAME(arg1)
|
||||
|
||||
struct somebody
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
#line 1337 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#line 1329 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
BOOST_PARAMETER_TEMPLATE_KEYWORD(class_type)
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
|
||||
#line 1353 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
#line 1344 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
namespace boost { namespace python {
|
||||
|
||||
namespace tag { struct class_type; } // keyword tag type
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 35 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter.hpp>
|
||||
|
||||
namespace test
|
||||
@@ -31,7 +30,6 @@ namespace test
|
||||
}
|
||||
using namespace test;
|
||||
int x =
|
||||
#line 19
|
||||
new_window("alert", _width=10, _titlebar=false);
|
||||
|
||||
smart_ptr<
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
#line 472 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter/name.hpp>
|
||||
|
||||
BOOST_PARAMETER_NAME(graph)
|
||||
@@ -17,7 +16,6 @@ struct dfs_visitor
|
||||
int vertex_index = 0;
|
||||
|
||||
}
|
||||
#line 446 "/home/daniel/dev/boost/trunk/libs/parameter/doc/index.rst"
|
||||
#include <boost/parameter/preprocessor.hpp>
|
||||
|
||||
namespace graphs
|
||||
|
||||
0
test/macros.cpp
Normal file → Executable file
0
test/macros.cpp
Normal file → Executable file
0
test/maybe.cpp
Normal file → Executable file
0
test/maybe.cpp
Normal file → Executable file
0
test/mpl.cpp
Normal file → Executable file
0
test/mpl.cpp
Normal file → Executable file
0
test/normalized_argument_types.cpp
Normal file → Executable file
0
test/normalized_argument_types.cpp
Normal file → Executable file
0
test/ntp.cpp
Normal file → Executable file
0
test/ntp.cpp
Normal file → Executable file
0
test/optional_deduced_sfinae.cpp
Normal file → Executable file
0
test/optional_deduced_sfinae.cpp
Normal file → Executable file
0
test/preprocessor.cpp
Normal file → Executable file
0
test/preprocessor.cpp
Normal file → Executable file
0
test/preprocessor_deduced.cpp
Normal file → Executable file
0
test/preprocessor_deduced.cpp
Normal file → Executable file
1
test/python_test.cpp
Normal file → Executable file
1
test/python_test.cpp
Normal file → Executable file
@@ -2,6 +2,7 @@
|
||||
// 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)
|
||||
|
||||
#include <math.h>
|
||||
#include <boost/python.hpp>
|
||||
#include <boost/parameter/preprocessor.hpp>
|
||||
#include <boost/parameter/keyword.hpp>
|
||||
|
||||
0
test/sfinae.cpp
Normal file → Executable file
0
test/sfinae.cpp
Normal file → Executable file
0
test/singular.cpp
Normal file → Executable file
0
test/singular.cpp
Normal file → Executable file
0
test/timings.txt
Normal file → Executable file
0
test/timings.txt
Normal file → Executable file
0
test/tutorial.cpp
Normal file → Executable file
0
test/tutorial.cpp
Normal file → Executable file
0
test/unwrap_cv_reference.cpp
Normal file → Executable file
0
test/unwrap_cv_reference.cpp
Normal file → Executable file
Reference in New Issue
Block a user