Hi Folks,

I have been using GNUstep Foundation for a while as a portable platform base for Linux, Darwin and OS X/Darwin. It works very well - up until now, I haven't found a bug, and technically, I still haven't!

While tracking one of my own bugs I have just noticed that - [NSAutoreleasePool drain] is a no-op for non-Garbage Collected environments. This behaviour is documented at http://www.gnustep.org/resources/documentation/Developer/Base/Reference/index.html and it does indeed work as documented.

This is unfortunate as the Apple version of -[NSAutoreleasePool drain] calls [-NSAutoreleasePool release] for non-garbage collected environments, and is encouraged by Apple as an alternative to - [NSAutoreleasePool release] in all their example and other source code as it behaves correctly in Garbage Collected and non-Garbage Collected environments. Apple's and GNUstep's -[NSAutoreleasePool release] behave similarly - a no-op for Garbage Collected environments and release the NSAutoreleasePool in non-Garbage Collected environments.

May I humbly suggest that GNUstep's -[NSAutoreleasePool drain] is updated to behave exactly like Apple's - IE to call - [NSAutoreleasePool release] in non-Garbage Collected environments? This is easy to work around, but I expect that I won't be the first to fail to notice the difference! If this has come up before, and been voted down, I'll understand. But searching the archives for

Regards,
Chris
mailto:[email protected]



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

Reply via email to