Boost logo

Boost :

From: John Maddock (john_at_[hidden])
Date: 2007-10-27 12:58:21


I'm having a problem using real_parser, I define the parser as:

real_parser<some-type> const rr_p;

Then use it as:

str_p("range")[assign_a(started, false)] && rr_p[assign_a(a)] &&
rr_p[assign_a(b)]

Followed by a list of other alternative commands.

When some-type is float/double/long double it all works OK, but as soon as I
change some-type to boost::math::ntl::RR then I have two problems:

1) The code doesn't compile: spirit looks for std::pow rather than relying
on ADL to find the right overload, I can work around this one for now by
importing boost::math::ntl::pow into namespace std.
2) The parser doesn't work, any simple command like "range 0 1" is rejected
as invalid.

Is there something else I need to do here to enable support for UDT's?

Thanks, John.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk