On 23 Nov 2008, at 13:40, David Chisnall wrote:
Can we insert a assert into NSObject's methodSignatureForSelector to check for this? Sometimes sel_get_type(aSel) will be NULL (e.g. if the method was called via @selector()), but in this case there's nothing we can do other than assume that the programmer knows what he or she is doing.

Obviously this would come with a small performance penalty, but forwarding invocations is already around 300 times slower than a direct message send and this would make debugging certain categories of problem a lot easier if people got a friendly 'method %s called with incorrect signature' error.

Good idea ... I have added such a check in svn trunk.


_______________________________________________
Gnustep-dev mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/gnustep-dev

Reply via email to