I have to parse a string that can optionally have square brackets in it. For e.g. This can be my token string:
xyz[aa:bb]:blah
I have used rules like
- +(~qi::char_("\r\n;,="))
- +(~qi::char_("\r\n;,=") | "[" | "]")
- +(qi::char_ - qi::char_("\r\n;,="))
But none of them accepts the square brackets. Is there some special handling of [] in the parser?