Boost logo

Boost Users :

From: John Maddock (john_maddock_at_[hidden])
Date: 2003-07-16 05:35:47


> I'm trying to use RegEx::Grep(GrepCallback cb, ...) on Windows with VC6.
It
> works great with one exception.
>
> I really need the callback to be a method so that I can update attributes
in
> my instance. I've tried about 10 ways and can't get anywhere - VC6 keeps
> sending back errors. Some of the errors are obvious and some - well,
aren't
> templates wonderful whe it comes to error msgs?!@#$%
>
> I'm using MS stl and the example in the docs to get a generic function
> pointer doesn't work.
> This is the example in the regex docs:
> std::bind1st(std::mem_fun(&MyClass::callback), this)
>
> Then I tried:
> boost::bind(&MyClass::callback, this, _1)
> This simply produces a type that refuses to match GrepCallback. I wish the
> RegEx code just overloaded RegEx::Grep() to support this. (Is it more
> crossplatform and the STL way to do things?)
>
> I tried several other things including direct casts to GerpCallback, but
I'm
> stuck. Any help in this area would be great.

You can't do what you are trying to do with RegEx::Grep, sorry, please
remember that this is a simplified example class...

John.


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