|
Boost Users : |
From: Jasper, Alexander (alexander.jasper_at_[hidden])
Date: 2002-10-29 12:47:52
-----Ursprüngliche Nachricht-----
Von: Mark Snelling [mailto:mark_at_[hidden]]
Gesendet: Dienstag, 29. Oktober 2002 17:44
An: Boost-Users_at_[hidden]
Betreff: [Boost-Users] boost::bind problem
[...]
typedef priority_queue<shared_ptr<Functor>,
vector<shared_ptr<Functor> >,
bind(less<int(),
bind(&Functor::priority, _1),
bind(&Functor::priority, _2))> MyQueue;
As far as I know you can't call a function in a typedef. bind(..) is a function call returning a predicate.
But does s.o. know how to use bind in this manner. I failed to, since the type of what bind returns is far to complex. And it is required if you want to to use bind in conjunction with maps or the priority_queue's.
You have to wrap the call in your own predicate.
alex
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