From ae05e30eac4e41de865858c94e600fff7bb86d69 Mon Sep 17 00:00:00 2001 From: Daniel Wallin Date: Sat, 6 May 2006 22:00:28 +0000 Subject: [PATCH] New PP syntax, initial checkin. [SVN r33948] --- test/preprocessor.cpp | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/test/preprocessor.cpp b/test/preprocessor.cpp index c211bae..fd9dd98 100755 --- a/test/preprocessor.cpp +++ b/test/preprocessor.cpp @@ -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)); + + tester( + name + , value + , index + ); + + return 1; +} + struct base { template @@ -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