Re: [Fwd: Re: [Boost-users] bind return value]
Marc Strämke <[email protected]> Wed, 10 Sep 2003 17:30:39 +0200
| Newsgroups | gmane.comp.embedded.stk.gui.devel |
|---|---|
| Message-ID | <[email protected]> |
Darren Vincent Hart wrote: > On Wed, 2003-09-10 at 08:08, Marc Strämke wrote: > >>Peter Dimov's Solution was basicly what i was thinking of, he's a few >>years ahead of me in metaprogramming though *g* >>I see one problem though , the first(simpler) solution makes no >>provisions for supporting signal arguments does it? As far as i >>understand the limitation of C++'s metaprogramming here we need one >>boost_return overload/specialisation for each number of arguments supported. >> > > > I don't think so. Libstk signals all accept bool(void) slots, so there > are no arguments. When we use bind to use a method that takes > arguments, it (bind) returns a functor that returns the same thing as > the method, but takes no arguments, so I don't think this is an issue. > I am implementing a test case atm (including argument passing to > "bind'ed" slots). That is absolutely right, but we do have signals that have arguments, i mean the signal, not the slot! For example pre_draw gets a rectangle, or on_event gets an event_ptr. It should be sufficient to provide a one argument form only though! > > Darren >