Jump to content
  • Advertisement
Sign in to follow this  
Puzzler183

Boost spirit troubles

This topic is 4557 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm in the middle of writing quite a large parser which uses ast_parse and I've run into a problem:
openingBrace = discard_node_d[ch_p('{') | "<%"];
closingBrace = discard_node_d[ch_p('}') | "%>"];
semicolon = discard_node_d[ch_p(';')];


Those rules are generating zero-length nodes in my parse tree, instead of nothing like the documentation says they should... Any ideas? Also, using no_node_d has the same problem.

Share this post


Link to post
Share on other sites
Advertisement
I was running into the same problem about a year and a half ago. I guess they never got around to fixing the ast_parse issues.

Share this post


Link to post
Share on other sites
Yeah... Turns out that if I put that in the higher rules that use those rules it works... But it's pretty annoying and is cluttering my code a lot.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!