663 Commits

Author SHA1 Message Date
Edward Diener
a195406157 Merge pull request #30 from CromwellEnage/tagged_argument_rref
Add missing boost::parameter::aux::tagged_argument_rref::operator[] overloads
2018-11-16 05:10:01 -05:00
CromwellEnage
3c494b663f Add missing boost::parameter::aux::tagged_argument_rref::operator[] overloads
Ultimately needed by "libs/graph/test/isomorphism.hpp"
2018-11-16 02:58:27 -05:00
Edward Diener
3ecf27411b Fixed code when specifying as_lvalue. 2018-11-14 20:22:54 -05:00
Edward Diener
e51b85d85f Distinguish same named run time tests by target. 2018-11-14 12:48:09 -05:00
Cromwell D. Enage
b72c8748a2 Merge with boostorg/parameter 2018-11-12 08:08:49 -05:00
Edward Diener
3bd15375ec Merge pull request #29 from CromwellEnage/comment_fix
Fix multi-line comment
2018-11-12 07:46:24 -05:00
CromwellEnage
05e7eee563 Restrict comment to single line. 2018-11-11 21:51:29 -05:00
CromwellEnage
661e8a699e Fix multi-line comment 2018-11-11 09:27:44 -05:00
Cromwell D. Enage
e5f96c8766 Merge with boostorg/parameter 2018-11-10 15:23:37 -05:00
Edward Diener
22129376c1 Merge pull request #28 from CromwellEnage/nested_keyword
Add keyword generation macro BOOST_PARAMETER_NESTED_KEYWORD
2018-11-10 15:12:16 -05:00
CromwellEnage
7a5d5358b9 Update boost::parameter::aux::tagged_argument
Make inheritance public.
2018-11-10 07:34:20 -05:00
CromwellEnage
65af83cdbe Update compose.cpp
Add code to test BOOST_PARAMETER_NESTED_KEYWORD.
2018-11-10 07:23:29 -05:00
CromwellEnage
61d17aeb43 Add keyword generation macro BOOST_PARAMETER_NESTED_KEYWORD
Upon approval and merging of this commit, replace the definition of BOOST_PARAMETER_NESTED_KEYWORD in <boost/accumulators/accumulators_fwd.hpp> with #include <boost/parameter/nested_keyword.hpp>.
2018-11-09 17:26:37 -05:00
Cromwell D. Enage
87b73e0fc8 Merge with boostorg/parameter 2018-11-09 11:33:40 -05:00
Edward Diener
6d9d61dd3a Merge pull request #27 from CromwellEnage/arg_list_as_mpl_assoc_seq
Add metafunction boost::parameter::is_argument_pack
2018-11-09 10:09:57 -05:00
CromwellEnage
66b4af0125 Add metafunction boost::parameter::is_argument_pack
Also upgrade boost::parameter::aux::arg_list, boost::parameter::aux::tagged_argument, and boost::parameter::aux::tagged_argument_rref to model the MPL Associative Sequence concept.
2018-11-09 00:32:34 -05:00
Cromwell D. Enage
aaf76c5759 Merge with boostorg/parameter 2018-11-08 01:50:20 -05:00
Edward Diener
6a53e1ac6b Merge pull request #26 from CromwellEnage/perfect_forwarding_with_cxx03_support
Reinstate C++03 workarounds
2018-11-07 18:18:11 -05:00
CromwellEnage
8ad69bc3f3 Fix .travis.yml
Mark ICE failures as expected.
2018-11-07 12:08:22 -05:00
CromwellEnage
00ac706ad8 Reinstate C++03 workarounds
Resolve merge conflicts arising from merging PR#23 into boostorg:develop.
2018-11-07 10:30:26 -05:00
Cromwell D. Enage
899891d1a3 Merge with boostorg/parameter 2018-11-07 10:14:24 -05:00
Edward Diener
80e1289bf0 Merge pull request #23 from CromwellEnage/perfect_forwarding
Support perfect forwarding
2018-11-07 08:21:55 -05:00
CromwellEnage
9b7eef1fe3 Update boost/parameter/config.hpp
Remove dependency on Boost.Move macros.
2018-11-06 14:11:12 -05:00
CromwellEnage
dceef04330 Update boost/parameter/aux_/maybe.hpp
Remove unused #include statements.
2018-10-31 01:52:54 -04:00
CromwellEnage
5fb1ef2871 Fix boost/parameter/parameters.hpp
Change erroneous #include statement from <boost/fusion/container/vector/vector_fwd.hpp> to <boost/fusion/container/list/list_fwd.hpp>.
2018-10-31 00:41:49 -04:00
CromwellEnage
44b34e10f6 Remove c++03 support.
* Replace calls to boost::forward with calls to std::forward.

<boost/parameter/config.hpp>
* Relax perfect forwarding requirements so that msvc-12.0 passes muster.

<boost/parameter/parameters.hpp>
* Use boost::mpl::vector if neither boost::fusion::list nor boost::fusion::deque are true variadic MPL sequences.

.travis.yml
appveyor.yml
* Remove test configurations of compilers that fail perfect forwarding requirements.
* Consolidate for fewer jobs.
2018-10-30 08:42:18 -04:00
CromwellEnage
0112583599 Support perfect forwarding
1. The end of section 3.2.1 of the current home page tutorial notes "that because of the forwarding problem, parameter::parameters::operator() can't accept non-const rvalues."  Add code to eliminate this problem.  As a positive side effect, Boost.Parameter-enabled functions and constructors are no longer bound by BOOST_PARAMETER_MAX_ARITY on compilers that support perfect forwarding. User code can now check for this support by detecting the configuration macro BOOST_PARAMETER_HAS_PERFECT_FORWARDING, or manually turn off this support by defining the configuration macro BOOST_PARAMETER_DISABLE_PERFECT_FORWARDING.  See "test/evaluate_category.cpp" and "test/preprocessor_eval_category.cpp" for example usage.

2. Add parameter category qualifiers "consume" and "move_from"(current qualifiers are "in", "out", "in_out", and "forward") based on http://www.modernescpp.com/index.php/c-core-guidelines-how-to-pass-function-parameters.

3. Update documentation to reflect the above changes.
2018-10-29 10:10:01 -04:00
Cromwell D. Enage
77a9508a65 Merge with boostorg/parameter 2018-10-29 07:39:29 -04:00
Edward Diener
cace644c0e Merge pull request #22 from CromwellEnage/restructure_tests
Restructure tests
2018-10-29 05:02:57 -04:00
CromwellEnage
d526784e05 FIx misspelling. 2018-10-28 23:34:31 -04:00
CromwellEnage
5b554b5f44 Remove dependency on boost::container::string
Replace with std::string.
2018-10-28 22:49:55 -04:00
CromwellEnage
06a0cc79e5 Prettify code 2018-10-28 22:14:17 -04:00
CromwellEnage
278a728906 Restructure tests.
<boost/parameter/parameters.hpp>:
* Add preprocessor conditional statement to prevent generation of ill-formed function call operator overloads.

"test/maybe.cpp"
"test/singular.cpp"
"test/tutorial.cpp"
"test/sfinae.cpp"
"test/earwicker.cpp"
* Replace BOOST_PARAMETER_KEYWORD statements with BOOST_PARAMETER_NAME statements.

"test/optional_deduced_sfinae.cpp"
"test/normalized_argument_types.cpp"
"test/literate/*.cpp"
* Use Boost.Core.LightweightTest where int main() is available.
* Replace assert statements with BOOST_TEST_EQ statements.

"test/basics.hpp"
* Remove preprocessor statements regarding borland, gcc-2, and msvc workarounds.

"test/ntp.cpp"
"test/sfinae.cpp"
"test/earwicker.cpp"
"test/normalized_argument_types.cpp"
"test/basics.hpp"
* Add preprocessor conditional statement to #error out if BOOST_PARAMETER_MAX_ARITY is set to an insufficient value.

"test/basics.cpp"
"test/deduced.cpp"
"test/macros.cpp"
"test/preprocessor.cpp"
"test/preprocessor_deduced.cpp"
* Replace S and char const* expressions with boost::container::string expressions.
* Uncomment any code that fails to compile, but add preprocessor conditional statement so that test suites can incorporate compile-fail statements regarding the code in question.
* Ensure that int main() returns boost::process_errors().

"test/literate/deduced-template-parameters0.cpp":
"test/literate/exercising-the-code-so-far0.cpp":
* Enclose BOOST_MPL_ASSERT statements within MPL_TEST_CASE block.

"test/literate/defining-the-keywords1.cpp":
* Add graphs::tag::graph::qualifier type definition because perfect forwarding code will check for it.
* Replace deprecated keyword::get() invocation with keyword::instance invocation.

test/Jamfile.v2:
* Add modifier <define>BOOST_PARAMETER_MAX_ARITY=# to run, run-fail, compile, and compile-fail statements to conserve compiler memory usage on GitHub's side.
* Add modifier <preserve-target-tests>off to run and run-fail statements to conserve executable space on GitHub's side.
* Separate bpl-test statement into its own target, parameter_python_test, which fails on xcode8.3 as well as on mingw and msvc compilers with address-model=64.
* The next commit (which will implement perfect forwarding) will subsume test/literate/Jamfile.v2 into this file.  Strangely enough, attempting to do so now will result in compiler errors.

.travis.yml:
* Add g++-4.7, g++-4.8, g++-4.9, clang++-3.5, clang++-3.6, clang++-3.7, clang++-3.8, clang++-3.9, clang++-4.0, xcode7.3, and xcode8.3 compiler configurations.
* Split compiler configurations by available CXXSTD values.  (This will keep the job times within limits for the next commit.)
* Ensure that the xcode8.3 compiler configurations exclude parameter_python_test from the test suite.

appveyor.yml:
* Add compiler configurations that support address-model=64 to the test matrix.
* Ensure that the new configurations exclude parameter_python_test from the test suite.
2018-10-28 13:13:07 -04:00
Cromwell D. Enage
79e042b590 Merge with boostorg/parameter 2018-10-25 22:29:20 -04:00
Edward Diener
57e3674bdd Merge pull request #21 from CromwellEnage/qualified_name
Support additional parameter categories
2018-10-25 21:59:19 -04:00
CromwellEnage
7441b2e72b Support additional parameter categories
Add parameter category qualifier "forward" (current qualifiers are "in", "out", and "in_out") based on http://www.modernescpp.com/index.php/c-core-guidelines-how-to-pass-function-parameters.  Add new usage syntax BOOST_PARAMETER_NAME((object-name), namespace-name) qualifier(tag-name)) and BOOST_PARAMETER_NAME(qualifier(name)).  (Existing code that uses qualifiers directly and correctly with BOOST_PARAMETER_FUNCTION and other code generation macros should remain unaffected for now, so no breaking changes.)  The reason for the change in usage is to enable applying of parameter category constraints to Boost.Parameter-enabled functions and constructors invoked through argument composition.  (Otherwise, it is currently possible to use argument composition to bypass parameter category constraints applied in BOOST_PARAMETER_FUNCTION et. al.) See "test/compose.cpp" for example usage.
2018-10-25 19:17:41 -04:00
Cromwell D. Enage
105bde609d Merge with boostorg/parameter 2018-10-25 14:00:08 -04:00
Edward Diener
1f25e851bc Merge pull request #20 from CromwellEnage/function_call_operator
Support Boost.Parameter-enabled function call operators.
2018-10-25 10:47:02 -04:00
CromwellEnage
c54b59f8b7 Support Boost.Parameter-enabled function call operators.
* Add code generation macros BOOST_PARAMETER_FUNCTION_CALL_OPERATOR and BOOST_PARAMETER_CONST_FUNCTION_CALL_OPERATOR to <boost/parameter/preprocessor.hpp>.
* Also, add documentation for BOOST_PARAMETER_CONST_MEMBER_FUNCTION, BOOST_PARAMETER_BASIC_FUNCTION, BOOST_PARAMETER_BASIC_MEMBER_FUNCTION, and BOOST_PARAMETER_BASIC_CONST_MEMBER_FUNCTION.
2018-10-25 07:58:11 -04:00
Cromwell D. Enage
8dcdeb307c Merge with boostorg/parameter 2018-10-25 05:55:34 -04:00
Edward Diener
3eb4c31f6f Merge pull request #18 from CromwellEnage/more_modular
Restructure code
2018-10-24 21:53:21 -04:00
CromwellEnage
b0785c2931 Update documentation
Document that boost::parameter::required, boost::parameter::optional, and boost::parameter::deduced are defined in their own header files, which are in turn #included by <boost/parameter/parameters.hpp>.
2018-10-24 16:54:44 -04:00
CromwellEnage
0fdf92a4e3 Update keyword.hpp
Add #include statement for forward declaration.
2018-10-24 12:42:14 -04:00
CromwellEnage
5f5d777691 Restructure code
<boost/parameter/name.hpp>:
* Move support metafunction definitions and BOOST_PARAMETER_TAG_PLACEHOLDER_TYPE macro definition to <boost/parameter/aux_/name.hpp>.
* Move BOOST_PARAMETER_IS_BINARY macro definition to <boost/parameter/aux_/preprocessor/is_binary.hpp>.
* Use BOOST_PARAMETER_TAG_PLACEHOLDER_TYPE macro.
2018-10-24 12:32:27 -04:00
CromwellEnage
2169c5adb4 Restructure code
<boost/parameter/aux_/arg_list.hpp>:
Move forward declarations to their own header files.

<boost/parameter/aux_/tagged_argument.hpp>:
* Move boost::parameter::aux::tagged_argument_base, boost::parameter::aux::is_tagged_argument_aux, and boost::parameter::aux::is_tagged_argument to <boost/parameter/aux_/is_tagged_argument.hpp>
* Remove unnecessary forward declarations.

<boost/parameter/parameters.hpp>:
* Move support metafunction definitions to their own header files in directory boost/parameter/aux_/pack.
* Move support macro definitions to <boost/parameter/aux_/preprocessor/no_perfect_forwarding_begin.hpp> and their corresponding #undef statements to <boost/parameter/aux_/preprocessor/no_perfect_forwarding_end.hpp>.

<boost/parameter/aux_/overloads.hpp> works at the preprocessor level, so move to <boost/parameter/aux_/preprocessor/overloads.hpp>.

<boost/parameter/preprocessor.hpp>:
* Move voidstar type definition to <boost/parameter/aux_/void.hpp>.
* Move support metafunctions to their own header files in directory boost/parameter/aux_/pp_impl.
* Move support macros to header files in directory boost/parameter/aux_/preprocessor/impl.
2018-10-24 12:09:26 -04:00
Cromwell D. Enage
38ef081b68 Merge with boostorg/parameter 2018-10-23 15:21:48 -04:00
Edward Diener
3fdc70d227 Merge pull request #17 from CromwellEnage/compose_with_function_as_argument
Upgrade boost::parameter::aux::tagged_argument
2018-10-23 15:02:02 -04:00
CromwellEnage
8df8cb6417 Update test suite
test/compose.cpp:
Change workarounds from boost::function to std::function since msvc-11.0 reports having a C++11-compliant <functional> header.
Add LIBS_PARAMETER_TEST_RUN_FAILURE configuration macro to facilitate run-fail testing.

test/Jamfile.v2:
Replaced deprecated test-suite statement with alias statements.
Added run-fail test case under its own alias statement.

appveyor.yml:
Add mingw compiler configurations to the test matrix.
Update msvc-11.0 configuration to also execute the run-fail test.

travis.yml:
Ensure that only the standard tests are run, not the run-fail test.
2018-10-23 03:42:03 -04:00
Cromwell D. Enage
7b3f03cb67 Merge pull request #2 from boostorg/develop
Merge with boostorg/parameter
2018-10-19 13:26:03 -04:00
CromwellEnage
42c2996cda Revert "Move preprocessor conditional expressions from main() in test/compose.cpp to tagged_argument.hpp" 2018-10-19 13:05:55 -04:00