Re: X3: Using dynamic Repetition Parser Directives
Mike Gresens <[email protected]>
| Newsgroups | gmane.comp.parsers.spirit.general |
|---|---|
| Message-ID | <[email protected]> |
Hi sehe,
I tried the provided solution:
auto r = rule<struct _r, std::string > {}
%= with<_n>(std::ref(n))
[ omit[uint_[number] ] >> *(eps [more] >> char_) >>
eps [done] ];
But the string remains empty.
And I remember something like: If you use semantic actions then you have to
do it everywhere.
auto r = rule<struct _r, std::string > {}
%= with<_n>(std::ref(n))
[ omit[uint_[number] ] >> *(eps [more] >> char_
[push] ) >> eps [done] ];
So using an explicit push action does fill the string for me.
Mike...
--
View this message in context: http://boost.2283326.n4.nabble.com/X3-Using-dynamic-Repetition-Parser-Directives-tp4682992p4683106.html
Sent from the spirit-general mailing list archive at Nabble.com.
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140