Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r66170 - trunk/boost/spirit/home/qi/directive
From: hartmut.kaiser_at_[hidden]
Date: 2010-10-24 21:01:35


Author: hkaiser
Date: 2010-10-24 21:01:35 EDT (Sun, 24 Oct 2010)
New Revision: 66170
URL: http://svn.boost.org/trac/boost/changeset/66170

Log:
Spirit: fixed a regression in qi::repeat[] I introduced with my last commit
Text files modified:
   trunk/boost/spirit/home/qi/directive/repeat.hpp | 21 +++++++++------------
   1 files changed, 9 insertions(+), 12 deletions(-)

Modified: trunk/boost/spirit/home/qi/directive/repeat.hpp
==============================================================================
--- trunk/boost/spirit/home/qi/directive/repeat.hpp (original)
+++ trunk/boost/spirit/home/qi/directive/repeat.hpp 2010-10-24 21:01:35 EDT (Sun, 24 Oct 2010)
@@ -225,20 +225,17 @@
             }
 
             // parse some more up to the maximum specified
- if (!iter.got_max(i)) {
- do {
- if (!subject.parse(save, last, context, skipper, val) ||
- !traits::push_back(attr, val))
- {
- break;
- }
- first = save;
- traits::clear(val);
- } while (!iter.got_max(++i));
- }
- else {
+ for (/**/; !iter.got_max(i); ++i) {
+ if (!subject.parse(save, last, context, skipper, val) ||
+ !traits::push_back(attr, val))
+ {
+ break;
+ }
                 first = save;
+ traits::clear(val);
             }
+
+ first = save;
             return true;
         }
 


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