Merge pull request #124 from Flast/feature/ticket-11157-remove-BOOST_PP_IS_EMPTY

Remove use of BOOST_PP_IS_EMPTY.
This commit is contained in:
Joel de Guzman
2016-02-17 04:45:16 +08:00
32 changed files with 292 additions and 256 deletions

View File

@ -32,13 +32,17 @@
#include <iostream>
#include <string>
namespace namespaced_type {
typedef int integer;
}
namespace ns
{
struct point
{
int x;
int y;
int z;
namespaced_type::integer z;
};
#if !BOOST_WORKAROUND(__GNUC__,<4)
@ -104,7 +108,7 @@ namespace ns
BOOST_FUSION_ADAPT_STRUCT(
ns::bar,
foo_.x, // test that adapted members can actually be expressions
y
(auto , y)
)
BOOST_FUSION_ADAPT_STRUCT(
@ -119,8 +123,8 @@ namespace ns
BOOST_FUSION_ADAPT_STRUCT(
ns::point,
(int, x)
(int, y)
(BOOST_FUSION_ADAPT_AUTO, z)
(auto, y)
(namespaced_type::integer, z)
)
# if !BOOST_WORKAROUND(__GNUC__,<4)
@ -128,17 +132,18 @@ namespace ns
ns::point_with_private_attributes,
(int, x)
(int, y)
(BOOST_FUSION_ADAPT_AUTO, z)
(auto, z)
)
# endif
struct s { int m; };
BOOST_FUSION_ADAPT_STRUCT(s, (BOOST_FUSION_ADAPT_AUTO, m))
BOOST_FUSION_ADAPT_STRUCT(s, (auto, m))
BOOST_FUSION_ADAPT_STRUCT(
ns::bar,
(BOOST_FUSION_ADAPT_AUTO, foo_.x) // test that adapted members can actually be expressions
(BOOST_FUSION_ADAPT_AUTO, y)
(auto, foo_.x) // test that adapted members can actually be expressions
(BOOST_FUSION_ADAPT_AUTO, y) // Mixing auto & BOOST_FUSION_ADAPT_AUTO
// to test backward compatibility
)
BOOST_FUSION_ADAPT_STRUCT(