mirror of
https://github.com/boostorg/parameter.git
synced 2026-01-19 04:22:13 +00:00
New PP syntax, initial checkin.
[SVN r33948]
This commit is contained in:
@@ -66,6 +66,28 @@ BOOST_PARAMETER_FUNCTION((int), g, tag,
|
||||
return 1;
|
||||
}
|
||||
|
||||
BOOST_PARAMETER_FUNCTION2((int), h, tag,
|
||||
(required
|
||||
(tester, *)
|
||||
(name, *)
|
||||
)
|
||||
(optional
|
||||
(value, *, 1.f)
|
||||
(out(index), (int), 2)
|
||||
)
|
||||
)
|
||||
{
|
||||
BOOST_MPL_ASSERT((boost::is_same<index_type, int const>));
|
||||
|
||||
tester(
|
||||
name
|
||||
, value
|
||||
, index
|
||||
);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
struct base
|
||||
{
|
||||
template <class Args>
|
||||
@@ -190,6 +212,13 @@ int main()
|
||||
, 2
|
||||
);
|
||||
|
||||
h(
|
||||
tester = values(S("foo"), 1.f, 2)
|
||||
, name = S("foo")
|
||||
, 1.f
|
||||
, 2
|
||||
);
|
||||
|
||||
class_ x(
|
||||
tester = values(S("foo"), 1.f, 2)
|
||||
, S("foo"), test::index = 2
|
||||
|
||||
Reference in New Issue
Block a user