Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r78351 - trunk/libs/spirit/example/lex
From: jamin.hanson_at_[hidden]
Date: 2012-05-06 10:27:04


Author: ben_hanson
Date: 2012-05-06 10:27:03 EDT (Sun, 06 May 2012)
New Revision: 78351
URL: http://svn.boost.org/trac/boost/changeset/78351

Log:
Changed '*' to '+', as per lex example in the comment.
Text files modified:
   trunk/libs/spirit/example/lex/print_number_tokenids.cpp | 4 ++--
   1 files changed, 2 insertions(+), 2 deletions(-)

Modified: trunk/libs/spirit/example/lex/print_number_tokenids.cpp
==============================================================================
--- trunk/libs/spirit/example/lex/print_number_tokenids.cpp (original)
+++ trunk/libs/spirit/example/lex/print_number_tokenids.cpp 2012-05-06 10:27:03 EDT (Sun, 06 May 2012)
@@ -44,7 +44,7 @@
     print_numbers_tokenids()
       : print_numbers_tokenids::base_type(lex::match_flags::match_not_dot_newline)
     {
- this->self = lex::token_def<int>("[0-9]*") | ".|\n";
+ this->self = lex::token_def<int>("[0-9]+") | ".|\n";
     }
 };
 
@@ -58,7 +58,7 @@
       : print_numbers_grammar::base_type(start)
     {
         // we just know, that the token ids get assigned starting min_token_id
- // so, "[0-9]*" gets the id 'min_token_id' and ".|\n" gets the id
+ // so, "[0-9]+" gets the id 'min_token_id' and ".|\n" gets the id
         // 'min_token_id+1'.
 
         // this prints the token ids of the matched tokens


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