discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ANN: GNUstep Objective-C Runtime 1.4


From: David Chisnall
Subject: Re: ANN: GNUstep Objective-C Runtime 1.4
Date: Sat, 7 May 2011 10:52:34 +0100

On 7 May 2011, at 09:19, Wolfgang Lux wrote:

> David Chisnall wrote:
> 
>> GNUstep Objective-C Runtime 1.4
>> ===============================
>> 
>> This is the fifth official release of the GNUstep Objective-C runtime (a.k.a.
>> libobjc2).  This runtime was designed to support the features of Objective-C 
>> 2
>> for use with GNUstep and other Objective-C programs.  Highlights of this
>> release include:
> 
> And, unfortunately, it seems to contain a major bug. The attached program 
> generates the incorrect output
> 
> new object is: <MyObject: 0x104b80>
> 
> with version 1.4 of the GNUstep Objective-C (compiled with gcc 4.5 on OS X, 
> and gcc 4.4 on Ubuntu 10.04). The correct output is
> 
> new object is: [MyObject:0x104b80]
> 
> and is produced with all other Objective-C runtimes, including version 1.3 of 
> the GNUstep runtime.

Thanks.  It was a small bug in the selector type hashing, causing "@@:" and 
"8@4@8:" to be regarded as different type encodings.  I've tweaked your test 
slightly to use the GNUstep testing framework and added it to the test suite.

I've also fixed the bug in the 1.4 release branch and updated the tarballs - I 
think you probably caught it before any packagers had got around to shipping 
the new release.

> Wolfgang
> 
> PS: Don't tell me that the release calls in the sample program are redundant. 
> I know you think they are, but I prefer writing code which is correct 
> independent of its context.

The only one that is redundant is the destruction of the top-level autorelease 
pool, which is an antipattern that forces potentially large numbers of 
destructors to run when the program exits, which can cause heavy swapping 
(since stuff in the top-level autorelease pool is often not referenced for a 
very long time, it is most likely to be swapped out) at a time when the user 
wants to reclaim the program's memory for other things.

David


reply via email to

[Prev in Thread] Current Thread [Next in Thread]