Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r60373 - trunk/boost/spirit/home/support/iterators/detail
From: hartmut.kaiser_at_[hidden]
Date: 2010-03-08 20:49:15


Author: hkaiser
Date: 2010-03-08 20:49:14 EST (Mon, 08 Mar 2010)
New Revision: 60373
URL: http://svn.boost.org/trac/boost/changeset/60373

Log:
Spirit: fixing another bug in multi_pass
Text files modified:
   trunk/boost/spirit/home/support/iterators/detail/buffering_input_iterator_policy.hpp | 10 ++++++----
   1 files changed, 6 insertions(+), 4 deletions(-)

Modified: trunk/boost/spirit/home/support/iterators/detail/buffering_input_iterator_policy.hpp
==============================================================================
--- trunk/boost/spirit/home/support/iterators/detail/buffering_input_iterator_policy.hpp (original)
+++ trunk/boost/spirit/home/support/iterators/detail/buffering_input_iterator_policy.hpp 2010-03-08 20:49:14 EST (Mon, 08 Mar 2010)
@@ -106,14 +106,16 @@
 
             void advance_input()
             {
- curtok_ = *input_++;
- input_is_valid_ = true;
+ ++input_;
+ input_is_valid_ = false;
             }
 
             result_type& get_input()
             {
- if (!input_is_valid_)
- advance_input();
+ if (!input_is_valid_) {
+ curtok_ = *input_;
+ input_is_valid_ = true;
+ }
                 return curtok_;
             }
 


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