|
Boost-Commit : |
From: chochlik_at_[hidden]
Date: 2008-07-08 09:46:12
Author: matus.chochlik
Date: 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
New Revision: 47221
URL: http://svn.boost.org/trac/boost/changeset/47221
Log:
- Renamed some of the base-class registering macros
Text files modified:
sandbox/mirror/boost/mirror/meta_inheritance.hpp | 4 ++--
sandbox/mirror/libs/mirror/doc/xml/mirror/_library.xml | 1 +
sandbox/mirror/libs/mirror/example/registering/classes.cpp | 15 ++++++++++-----
sandbox/mirror/libs/mirror/example/registering/virtual_bases.cpp | 20 ++++++++++----------
sandbox/mirror/libs/mirror/example/traversal/sample_meta_path.cpp | 20 ++++++++++----------
sandbox/mirror/libs/mirror/example/traversal/sample_visitor.cpp | 20 ++++++++++----------
6 files changed, 43 insertions(+), 37 deletions(-)
Modified: sandbox/mirror/boost/mirror/meta_inheritance.hpp
==============================================================================
--- sandbox/mirror/boost/mirror/meta_inheritance.hpp (original)
+++ sandbox/mirror/boost/mirror/meta_inheritance.hpp 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -159,7 +159,7 @@
* and inheritance type specifier. The numbering starts from
* zero, declarations must be ordered by number.
*/
-#define BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(NUMBER, A_BASE_CLASS) \
+#define BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(NUMBER, A_BASE_CLASS) \
BOOST_PP_COMMA_IF(NUMBER) \
meta_inheritance<\
mpl::int_<NUMBER>, \
@@ -183,7 +183,7 @@
* and virtual inheritance type specifier. The numbering starts from
* zero, declarations must be ordered by number.
*/
-#define BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(NUMBER, ACCESS_SPEC, A_BASE_CLASS) \
+#define BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(NUMBER, ACCESS_SPEC, A_BASE_CLASS) \
BOOST_PP_COMMA_IF(NUMBER) \
meta_inheritance<mpl::int_<NUMBER>, A_BASE_CLASS, ACCESS_SPEC##_, virtual_base_>
Modified: sandbox/mirror/libs/mirror/doc/xml/mirror/_library.xml
==============================================================================
--- sandbox/mirror/libs/mirror/doc/xml/mirror/_library.xml (original)
+++ sandbox/mirror/libs/mirror/doc/xml/mirror/_library.xml 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -267,6 +267,7 @@
- Template class names for std::map and ::std::set are now build also with the comparator argument
- The meta-attribute declaration macros were rewritten nearly from scratch
+ - Renamed some of the base-class registering macros
- Tested with MSVC++ 2008 EE On Vista
</revision>
Modified: sandbox/mirror/libs/mirror/example/registering/classes.cpp
==============================================================================
--- sandbox/mirror/libs/mirror/example/registering/classes.cpp (original)
+++ sandbox/mirror/libs/mirror/example/registering/classes.cpp 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -107,13 +107,13 @@
};
//
// a static member attribute
- static const short a_short;
+ static short a_short;
// a mutable member attribute
- mutable long a_long;
+ mutable wchar_t a_widechar;
};
-const short bar::a_short = 123;
+short bar::a_short = 123;
} // namespace detail
@@ -149,11 +149,11 @@
*/
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::test::feature::detail::foo)
// a simple base (not virtual, nor explicitly public/protected/private)
- BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::test::feature::detail::foo_base)
+ BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::test::feature::detail::foo_base)
// a public non-virtual base
BOOST_MIRROR_REG_BASE_CLASS(1, public, ::test::feature::detail::foo_base2)
// a virtual protected base
- BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(2, protected, ::test::feature::detail::foo_base3)
+ BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(2, protected, ::test::feature::detail::foo_base3)
BOOST_MIRROR_REG_BASE_CLASSES_END
// since bar has only one base we can register it this way more quickly
@@ -209,6 +209,11 @@
{dest = DestType(const_cast<Class&>(instance).get_bool()); return dest;},
{instance.set_bool(value);}
)
+ //
+ // register a static member attribute
+ BOOST_MIRROR_REG_SIMPLE_CLASS_ATTRIB(static, short, a_short)
+ // register a mutable member attribute
+ BOOST_MIRROR_REG_SIMPLE_CLASS_ATTRIB(mutable, wchar_t, a_widechar)
BOOST_MIRROR_REG_CLASS_ATTRIBS_END
/** This is a pretty printer template that prints
Modified: sandbox/mirror/libs/mirror/example/registering/virtual_bases.cpp
==============================================================================
--- sandbox/mirror/libs/mirror/example/registering/virtual_bases.cpp (original)
+++ sandbox/mirror/libs/mirror/example/registering/virtual_bases.cpp 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -102,34 +102,34 @@
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::D)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::E)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(2, ::Test::D)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::B)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::C)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(2, ::Test::D)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::G)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::H)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::G)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::F)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::G)
BOOST_MIRROR_REG_BASE_CLASSES_END
Modified: sandbox/mirror/libs/mirror/example/traversal/sample_meta_path.cpp
==============================================================================
--- sandbox/mirror/libs/mirror/example/traversal/sample_meta_path.cpp (original)
+++ sandbox/mirror/libs/mirror/example/traversal/sample_meta_path.cpp 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -96,34 +96,34 @@
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::D)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::E)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(2, ::Test::D)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::B)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::C)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(2, ::Test::D)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::G)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::H)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::G)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::F)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::G)
BOOST_MIRROR_REG_BASE_CLASSES_END
Modified: sandbox/mirror/libs/mirror/example/traversal/sample_visitor.cpp
==============================================================================
--- sandbox/mirror/libs/mirror/example/traversal/sample_visitor.cpp (original)
+++ sandbox/mirror/libs/mirror/example/traversal/sample_visitor.cpp 2008-07-08 09:46:11 EDT (Tue, 08 Jul 2008)
@@ -96,34 +96,34 @@
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::D)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::A)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::A)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::E)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::B)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::C)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(2, ::Test::D)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::B)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::C)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(2, ::Test::D)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::G)
-BOOST_MIRROR_REG_BASE_CLASS_VIRTUAL(0, public, ::Test::E)
+BOOST_MIRROR_REG_VIRTUAL_BASE_CLASS(0, public, ::Test::E)
BOOST_MIRROR_REG_BASE_CLASSES_END
BOOST_MIRROR_REG_BASE_CLASSES_BEGIN(::Test::H)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(0, ::Test::F)
-BOOST_MIRROR_REG_BASE_CLASS_SIMPLE(1, ::Test::G)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(0, ::Test::F)
+BOOST_MIRROR_REG_SIMPLE_BASE_CLASS(1, ::Test::G)
BOOST_MIRROR_REG_BASE_CLASSES_END
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk