Boost Users :
From: Richard Crossley (rdc_at_[hidden])
Date: 2006-05-31 11:24:04
Solved. Completely down to operator error.
FWIW. Some brackets had become misplaced.
struct parameters : boost::parameter::parameters<
boost::parameter::required<tag::a > >,
boost::parameter::optional <tag::b > // ouch!
Sorry for the noise.
> -----Original Message-----
> From: boost-users-bounces_at_[hidden] [mailto:boost-users-
> bounces_at_[hidden]] On Behalf Of Richard Crossley
> Sent: 31 May 2006 11:24
> To: boost-users_at_[hidden]
> Subject: [Boost-users] [Parameter] Positional arg after named arg
> With the parameter library is there any way to stop misuse as in;
> func(/*a = */1,b = 2); Fine, a is positional, b is named.
> func(a = 1,2);
> Happily compiles but probably isn't what was intended, the default
> value is used for the second parameter. Should positional arguments be
> allowed to occur after named arguments?
> Perusing the Parameter library docs I can't see any mention as to what
> should happen here.
> (using VC8.0 & cvs head)
> Boost-users mailing list
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