15 Most Recent [RSS]
NSMethodSignature and @encode
Here's the text of a bug I just filed against Apple's Cocoa docs:
Currently, NSMethodSignature's -getArgumentTypeAtIndex: method is very vaguely documented. In particular the docs say "Returns the type encoding for the argument at a given index" about its return value. It isn't really obvious that by "encoding" not just an arbitrary way to encode data is meant (like the _NSObjCValueType enum defined in NSInvocation.h, which is usually used along with NSMethodSignature), but rather Objective C's @encode() method of encoding types.
To help clarify this, it would help if the docs for -getArgumentTypeAtIndex: and -methodReturnType (which suffers the same issue) mentioned @encode and linked to the page where the possible return values are documented.
So, in short, this posting is a reminder to myself about the return type of -getArgumentTypeAtIndex: and -methodReturnType