XCode 2.2, templates, overloads, Obj-C types
XCode 2.2, templates, overloads, Obj-C types
- Subject: XCode 2.2, templates, overloads, Obj-C types
- From: Scott Ribe <email@hidden>
- Date: Tue, 15 Nov 2005 17:32:41 -0700
- Thread-topic: XCode 2.2, templates, overloads, Obj-C types
In 2.1 I got away with the following overloaded constructors:
template <typename Fun>
Functor(Fun fun)
: spImpl_(new FunctorHandler<Functor, Fun>(fun))
{}
template <class PtrObj, typename MemFn>
Functor(const PtrObj& p, MemFn memFn)
: spImpl_(new MemFunHandler<Functor, PtrObj, MemFn>(p, memFn))
{}
Functor( id target, SEL selector)
: spImpl_( new ObjCFunHandler<Functor, ResultType>(target,
selector))
{}
But in 2.2, constructing a functor with a pointer to an NSObject-derived
class and a selector instantiates the 2nd form, instead of calling the
third, which doesn't work, since selectors and member function pointers are
not actually interchangeable.
Bug? Feature that I don't understand? What to do here?
--
Scott Ribe
email@hidden
http://www.killerbytes.com/
(303) 665-7007 voice
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden