Boost logo

Boost Users :

Subject: Re: [Boost-users] [Spirit]Kleene star with arguments having optional attributes.
From: TONGARI (tongari95_at_[hidden])
Date: 2010-11-24 08:57:48


BTW, you can use qi::skip in this case:

bool r = qi::parse(begin, end, qi::skip('p')[*qi::char_], res);

it seems well-suited here.

2010/11/24, Paul Graphov <graphov_at_[hidden]>:
> Thanks, I didn't know that there is a dedicated Spirit mailing list.
>
> On 24 November 2010 15:49, TONGARI <tongari95_at_[hidden]> wrote:
>
>> 2010/11/24, Paul Graphov <graphov_at_[hidden]>:
>> > Is it possible to make such a parser without using semantic actions
>> > like [bind(&string::append, res, _1)] or something like that, which seem
>> > to be less elegant solution.
>>
>> The following works as expected:
>>
>> std::vector<boost::optional<char> > vec;
>> bool r = qi::parse(begin, end, *('p' | qi::char_), vec);
>>
>> Why std::string does not? I have no idea, either.
>>
>> You can go to https://lists.sourceforge.net/lists/listinfo/spirit-general
>> for more specific help.
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users_at_[hidden]
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>>
>


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net