Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r54280 - trunk/libs/spirit/doc
From: hartmut.kaiser_at_[hidden]
Date: 2009-06-23 11:22:16

Author: hkaiser
Date: 2009-06-23 11:22:15 EDT (Tue, 23 Jun 2009)
New Revision: 54280

Text files modified:
   trunk/libs/spirit/doc/faq.qbk | 22 ++++++++++++++++++++++
   trunk/libs/spirit/doc/spirit2.qbk | 2 +-
   2 files changed, 23 insertions(+), 1 deletions(-)

Modified: trunk/libs/spirit/doc/faq.qbk
--- trunk/libs/spirit/doc/faq.qbk (original)
+++ trunk/libs/spirit/doc/faq.qbk 2009-06-23 11:22:15 EDT (Tue, 23 Jun 2009)
@@ -8,6 +8,28 @@
 [section FAQ]
+[heading I'm getting multiple symbol definition errors while using Visual C++. Anything I could do about that?]
+Do you see strange multiple symbol definition linker errors mentioning
+`boost::mpl::failed` and `boost::spirit::qi::rule`? Then this FAQ entry might
+be for you.
+__mpl__ implements a macro `BOOST_MPL_ASSERT_MSG()` which essentially is a
+more powerfull version of static_assert. Unfortunately under certain
+circumstances using this macro may lead to the aformentioned linker errors.
+__spirit__ allows you to define a preprocessor constant disabling the usage
+of `BOOST_MPL_ASSERT_MSG()`, while switching to `BOOST_STATIC_ASSRT()` instead.
+If you define BOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG=1 (either by adding a
+`-DBOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG=1` on the compiler command line or by
+inserting a `#define BOOST_SPIRIT_DONT_USE_MPL_ASSERT_MSG 1` into your code
+before any spirit headers get included).
+Using this trick has no adverse effects on any of the functionality of
+__spirit__. The only change you might see while using this workaround are less
+verbose error messages generated from static_assert.
 [heading I'm very confused about the header hell in my boost/spirit directory. What's all this about?]
 The boost/spirit directory currently holds two versions of the Spirit library:

Modified: trunk/libs/spirit/doc/spirit2.qbk
--- trunk/libs/spirit/doc/spirit2.qbk (original)
+++ trunk/libs/spirit/doc/spirit2.qbk 2009-06-23 11:22:15 EDT (Tue, 23 Jun 2009)
@@ -28,7 +28,7 @@
 [def __phoenix__ [@../../phoenix/doc/html/index.html Phoenix]]
 [def __phoenix2__ [@../../phoenix/doc/html/index.html Phoenix2]]
 [def __fusion__ [@ Fusion]]
-[def __mpl__ [@ MPL]]
+[def __mpl__ [@ Boost.Mpl]]
 [def __boost__ [@ Boost]]
 [def __boost_tools__ [@ Boost Tools]]
 [def __spirit_list__ [@ Spirit Mailing List]]

Boost-Commit list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at