Boost logo

Boost Users :

From: Paul Thompson (friedegg_at_[hidden])
Date: 2003-06-12 09:43:44


--- In Boost-Users_at_[hidden], "Paul Thompson" <friedegg_at_n...>
wrote:
> --- In Boost-Users_at_[hidden], Alisdair Meredith
> <yg-boost-users_at_m...> wrote:
> > Paul Thompson wrote:
> >
> > > I thought about (among many others)
> > >
> > > for_each(filenames.begin(),
> > > filenames.end(),
> > > bind(&CDocumentAttachments::Execute, _2, _T
("print"),
> > > false));
> >
> > Looks good to me, but why have you changed _1 to _2? The
parameter you
> > are passing in this place is the same (pointer to your objects as
found
> > by dereferencing the iterator)
> >
> > If you change _2 to _1 I think it should work.
>
> Yeah, I tried that, but I got 39 errors! Hence playing with the
> placeholder - it got fewer errors. Sounds daft, I know.
>
> I don't have the code with me here. I'll try some more when I get
to
> work tomorrow.

Yes, it works fine now (using _1). I can't think what I must have
tried before. Blame it on the beer.

Thanks to you guys for your help.

Paul


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