|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r68908 - trunk/boost/spirit/home/qi/action
From: joel_at_[hidden]
Date: 2011-02-14 22:35:47
Author: djowel
Date: 2011-02-14 22:35:41 EST (Mon, 14 Feb 2011)
New Revision: 68908
URL: http://svn.boost.org/trac/boost/changeset/68908
Log:
Allow attribute compatibility with semantic actions
Text files modified:
trunk/boost/spirit/home/qi/action/action.hpp | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
Modified: trunk/boost/spirit/home/qi/action/action.hpp
==============================================================================
--- trunk/boost/spirit/home/qi/action/action.hpp (original)
+++ trunk/boost/spirit/home/qi/action/action.hpp 2011-02-14 22:35:41 EST (Mon, 14 Feb 2011)
@@ -103,9 +103,15 @@
, Context& context, Skipper const& skipper
, unused_type) const
{
- // synthesize the attribute since one is not supplied
typedef typename attribute<Context, Iterator>::type attr_type;
- typename attr_type attr;
+ typedef traits::make_attribute<attr_type, unused_type> make_attribute;
+
+ // synthesize the attribute since one is not supplied
+ typedef traits::transform_attribute<
+ typename make_attribute::type, attr_type, domain> transform;
+
+ typename make_attribute::type made_attr = make_attribute::call(unused_type());
+ typename transform::type attr = transform::pre(made_attr);
Iterator save = first;
if (subject.parse(first, last, context, skipper, attr))
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