Commit Graph

1407 Commits

Author SHA1 Message Date
Damien Buhl (alias daminetreg)
04ce8a788b Enabled new ADAPT_STRUCT_API for ADAPT_TPL_STRUCT. 2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
ce3f2d6020 Added new ADAPT_STRUCT API support for the ADAPT_STRUCT_AS_VIEW macro. 2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
687b2cf097 Factoring out of adapt_struct.hpp all the FILLER_* macros details.
As of BOOST_FUSION_ADAPT_STRUCT without type deduction, there were only
simple attributes filler. Now this need more complex logic to handle both
API: the backward compatible one with type specificiation, the one without
type specification and the non-variadic one which enables omitting the type
specification by providing BOOST_FUSION_ADAPT_AUTO instead of the type.

That's why I extracted the FILLER_* macros details in a separate source
file.
2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
c851252f65 Renaming macros for ADAPT_STRUCT to deduce type or take provided attribute types. 2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
557b3d2dc6 Fix detection of member_type parameter emptiness for BOOST_FUSION_ADAPT_STRUCT.
As BOOST_PP_IS_EMPTY is not a general purpose emptiness checker, we limit
the ways it can be used.
2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
7ef202b794 Moved BOOST_FUSION_ADAPT_STRUCT implementation details to detail/adapt_base.hpp 2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
02b776360a FEATURE: BOOST_FUSION_ADAPT_STRUCT can now also be called completely with
variadics arguments.

The following signature is possible :

 BOOST_FUSION_ADAPT_STRUCT(
        struct_name,
        member_name0,
        (BOOST_FUSION_ADAPT_AUTO, member_name1)
        (member_type2, member_name2)
	member_name3,
        ...
        )
2014-06-13 23:09:38 +02:00
Damien Buhl (alias daminetreg)
37fc1443ad Improve the BOOST_FUSION_ADAPT_STRUCT macro to work also when there is no variadic support.
This enable the following flexible macro signature when there is
no BOOST_PP_VARIADICS support:

BOOST_FUSION_ADAPT_STRUCT(
    struct_name,
    (member_type0, member_name0)
    (BOOST_FUSION_ADAPT_AUTO, member_name1)
    (,member_name2)
    ...
    )

If BOOST_PP_VARIADICS is active then there is quite more flexibility as it
allows to avoid the type specification:

BOOST_FUSION_ADAPT_STRUCT(
    struct_name,
    (member_type0, member_name0)
    (BOOST_FUSION_ADAPT_AUTO, member_name1)
    (,member_name2)
    (member_name3)
    ...
    )
2014-06-13 23:09:29 +02:00
Damien Buhl (alias daminetreg)
944c363787 Remove dependency to variadics macros for the old API not deducing types. 2014-06-13 23:07:49 +02:00
Damien Buhl (alias daminetreg)
6f6bfb3a27 EDITORIAL: Cleaning the ADAPT_STRUCT which can deduce types. 2014-06-13 23:07:32 +02:00
Damien Buhl (alias daminetreg)
04cbf0d4c6 BUGFIX: Presents the correct field name as a string even if type is deduced. 2014-06-13 23:07:32 +02:00
Damien Buhl (alias daminetreg)
703bff4ff9 FEATURE: Types of a struct can freely pe provided or deduced, following the user preferences. 2014-06-13 23:07:32 +02:00
Damien Buhl (alias daminetreg)
7e1c6cdf47 FEATURE: Type deduction for BOOST_FUSION_ADAPT_STRUCT_C_BASE, with preliminary support for providing or deducing the type. 2014-06-13 23:07:16 +02:00
Damien Buhl (alias daminetreg)
3ca94f5762 DOC: Add some comments to help me understand the adapt macros. 2014-06-13 23:04:09 +02:00
Damien Buhl (alias daminetreg)
c052b4b452 FEATURE: Making BOOST_FUSION_AUTO_ADAPT_STRUCT variadic. 2014-06-13 23:04:09 +02:00
Damien Buhl (alias daminetreg)
166132789a DOC: Document the BOOST_FUSION_AUTO* macros.
This documents the AUTO_ADAPT macros :
  * BOOST_FUSION_AUTO_ADAPT_STRUCT
  * BOOST_FUSION_AUTO_ADAPT_STRUCT_NAMED
  * BOOST_FUSION_AUTO_ADAPT_ASSOC_STRUCT
  * BOOST_FUSION_AUTO_ADAPT_ASSOC_STRUCT_NAMED
2014-06-13 23:04:09 +02:00
Damien Buhl (alias daminetreg)
435fb5c29f EDITORIAL: Reorganize imports. 2014-06-13 23:04:09 +02:00
Damien Buhl (alias daminetreg)
934463c7b4 FEATURE: BOOST_FUSION_AUTO_ADAPT_ASSOC_STRUCT_NAMED now allows defining a Random Access Sequence and an Associative sequence without providing the type. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
a5f87696f2 EDITORIAL: Rename the macro for type deduction to a more expressive and correct name. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
2d37b9c22c EDITORIAL: Fixes typos. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
f7b14aee35 FEATURE: BOOST_FUSION_AUTO_ADAPT_ASSOC_STRUCT now allows defining a Random Access Sequence and an Associative sequence without providing the type. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
8a132ea44a BUGFIX: Fix include path. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
5ffab5001e REFACTORING: reused the BOOST_FUSION_AUTO_ADAPT_STRUCT_NAMED_NS macro in BOOST_FUSION_AUTO_ADAPT_STRUCT_NAMED to mimic the non-AUTO versions. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
e58bd91f27 EDITORIAL: fixed indentation. 2014-06-13 23:04:08 +02:00
Damien Buhl (alias daminetreg)
5aa9a89fb8 FEATURE: BOOST_FUSION_AUTO_ADAPT_STRUCT_NAMED_NS which allows listing class attributes to adapt without specifying types. 2014-06-13 23:04:07 +02:00
Damien Buhl (alias daminetreg)
0d7ad9f6e2 FEATURE: BOOST_FUSION_AUTO_ADAPT_STRUCT_NAMED that does not require specifying the types of the fields. 2014-06-13 23:04:07 +02:00
Damien Buhl (alias daminetreg)
946957d3dc EDITORIAL: Change parameter names for consistency. 2014-06-13 23:04:07 +02:00
Damien Buhl (alias daminetreg)
3f965e00d3 #9516 BOOST_FUSION_AUTO_ADAPT_STRUCT that does not require specifying the types of the fields. 2014-06-13 23:04:07 +02:00
Joel de Guzman
10d363837a Merge pull request #8 from Flast/pr/msvc-10.0/test
Fix test error in msvc-10.0
2014-06-12 17:59:44 +08:00
Kohei Takahashi
25bb75e3f8 Fix test error in msvc-10.0
Including fusion/adapted/std_tuple.hpp will occur compile error.
  Therefore, entire test should be ignored.

Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-12 12:24:46 +09:00
Joel de Guzman
2cc2729f51 Merge pull request #7 from Flast/pr/adapt/tuple
Additional supports adapting (BoostTuple implementations
2014-06-09 21:11:03 +08:00
Kohei Takahashi
059c041659 Add test for convert seq to std::tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-09 21:59:06 +09:00
Kohei Takahashi
f7adae2b3d Add test for convert seq to tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-09 21:59:06 +09:00
Kohei Takahashi
f5fe438f14 Add mpl::clear implementation for std::tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-09 21:59:05 +09:00
Kohei Takahashi
38bcd6e779 Add mpl::clear implementation for Boost.Tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-09 21:59:05 +09:00
Kohei Takahashi
219b4124d7 Add convert implementation for std::tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-06-09 21:59:05 +09:00
Kohei Takahashi
39785ddb0e Add convert implementation for Boost.Tuple
Signed-off-by: Kohei Takahashi <flast@flast.jp>
2014-05-29 01:05:19 +09:00
Joel de Guzman
a0c1ec2018 Merge branch 'develop' 2014-05-27 08:45:08 +08:00
Joel de Guzman
1fde7cc293 Merge branch 'origin/develop' 2014-05-01 13:46:22 +08:00
Joel de Guzman
74a5d8804c reverting support for ref pending review 2014-05-01 13:44:45 +08:00
Joel de Guzman
8e4dd16b2d Merge pull request #5 from ericniebler/nil-hpp
Move definition of struct nil_ into its own header
2014-04-24 08:55:17 +08:00
Eric Niebler
d2633616dc fix copyright 2014-04-23 16:50:58 -07:00
Eric Niebler
01ed85e0e5 put struct nil_ in its own header to fix incomplete type error with nvcc 2014-04-23 16:47:03 -07:00
Joel de Guzman
6c904779af fixes #5208 2014-04-09 10:03:23 +08:00
Joel de Guzman
41e18be5cf Merge pull request #4 from jamboree/develop
flatten/flatten_view/ref
2014-04-04 14:50:25 +08:00
Jamboree
fd3a18ce1a flatten/flatten_view/ref 2014-04-04 14:38:38 +08:00
Joel de Guzman
21a2621cce Merge branch 'origin/develop' 2014-03-18 23:44:59 +08:00
Joel de Guzman
efad85a925 fixes Ticket #9455 2014-03-18 23:43:23 +08:00
Joel de Guzman
ad90e29cd6 Merge branch 'origin/develop' 2014-03-17 11:04:37 +08:00
Mateusz Łoskot
72912925cb Merge pull request #3 from correaa/patch-1
Update tag_of.hpp

Declare std::array with struct keyword, as per C++11, not class.
2014-02-08 10:28:43 +00:00