|
Boost : |
From: Doug Gregor (dgregor_at_[hidden])
Date: 2004-06-25 08:56:32
On Friday 25 June 2004 7:14 am, Peter Dimov wrote:
> > void notifier(const vector<int>& v)
> > {
> > stored_value = v.front();
> > }
> >
> > void test_semantic_values()
> > {
> > ....
> > ("int", po::value< vector<int> >()->notifier(notifier))
> > ;
> > }
> >
> > Where the 'notifier' member function is defines as:
> >
> > typed_value* notifier(function1<void, const T&> f)
> >
> > and in this case, T = vector<int>.
> >
> > Any ideas what I can do to make this work?
>
> IIRC boost::function requires the & in front of 'notifier'.
Yep. This was a side effect (on VC 6/7 only) of working around some bugs in VC
6/7.
Doug
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk