Boost logo

Boost Users :

From: Douglas Gregor (gregod_at_[hidden])
Date: 2002-06-27 10:17:09


Hi Bill,
  It's just a typo that's causing your problem: not_ok is declared like this:

    int not_ok(const D *d, int j) { return d->d() + j; }

  But the call to bind swaps the order of the 'const D*' and 'int' arguments:

    Foo f2 = boost::bind(&B::not_ok, b, _1, d);

  You want:

    Foo f2 = boost::bind(&B::not_ok, b, d, _1);

        Doug


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