|
Boost Users : |
From: Cory Nelson (phrosty_at_[hidden])
Date: 2004-11-06 18:51:11
Are there any tools to translate the various BNF formats into Spirit
code? I think this would be very useful.
On Sat, 06 Nov 2004 11:13:05 -0500, Jeffrey Holle
<jeff.holle_at_[hidden]> wrote:
> Of "course".
> That is what the optional operator is for.
> Something like:
> *alpha_p << !(ch_p('-') << *digit_p)
>
> Cory Nelson wrote:
> > I'm trying to write a parser with elements that might not occur - is
> > this possible?
> >
> > like:
> >
> > string ['-' number]
> >
> > that matches "foo" or "foo-123"
> >
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
-- Cory Nelson http://www.int64.org
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