Sorry, messed up again. 下面是被转发的邮件:
> 发件人: Maxthon Chan <[email protected]> > 主题: 回复: Bug: libobjc2 property name introspection. > 日期: 2013年4月10日 GMT+0800上午12时33分52秒 > 收件人: David Chisnall <[email protected]> > > Here is one, exposes this bug well: > > #import <Foundation/Foundation.h> > #import <objc/runtime.h> > > @interface TFoo : NSObject > > @property id foo; > @property id bar; > > - (id)method:(id)arg; > - (id)method2; > > @end > > @implementation TFoo > > @end > > int main(void) > { > unsigned int count = 0; > objc_property_t *properties = class_copyPropertyList([TFoo class], > &count); > for (NSUInteger i = 0; i < count; i++) > { > printf("%s\n", property_getName(properties[i])); > } > free(properties); > } > > To compile, use: > > clang `gnustep-config --objc-flags` `gnustep-config --base-libs` > -fobjc-nonfragile-abi -Xclang -fobjc-default-synthesize-properties -fobjc-arc > test.m -o test > > 在 2013-4-10,上午12:23,David Chisnall <[email protected]> 写道: > >> To clarify: >> >> A simple test case is one that is a single file that I can compile, with no >> dependencies other than the runtime, and which prints some output that is >> obviously right or wrong, or which asset()s the correct output. >> >> David >> >> On 9 Apr 2013, at 17:19, Maxthon Chan <[email protected]> wrote: >> >>> I will just copy/paste some code from my actual project. Compile without >>> -DGNUSTEP: >>> >> >> [ big blob of stuff omitted ] >> >>> >>> 在 2013-4-10,上午12:13,David Chisnall <[email protected]> 写道: >>> >>>> Please send me a (simple) test case. >>>> >>>> David >>>> >>>> On 9 Apr 2013, at 17:10, Maxthon Chan <[email protected]> wrote: >>>> >>>>> When I enumerate a class for all its properties and querying its name, >>>>> the name of last property is always cobbled. I have to use some "quick & >>>>> dirty" way (i.e add a dummy property at the end) to prevent this from >>>>> affecting. OS X does not have this issue, though. >>>>> >>>>> Can anyone figure out what is wrong? >>>>> _______________________________________________ >>>>> Gnustep-dev mailing list >>>>> [email protected] >>>>> https://lists.gnu.org/mailman/listinfo/gnustep-dev >>>> >>> >> >
_______________________________________________ Gnustep-dev mailing list [email protected] https://lists.gnu.org/mailman/listinfo/gnustep-dev
