[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fast enumeration
From: |
David Chisnall |
Subject: |
Re: Fast enumeration |
Date: |
Fri, 4 Feb 2011 23:10:42 +0000 |
On 4 Feb 2011, at 13:57, Jens Ayton wrote:
> I can't find a conveniently clean answer to this on the intergoogles, so:
> * Is fast enumeration usable in any stable release version of GNUstep?
Yes, I've been using it in Étoilé stuff for a year or so.
> * If so, what combination of GNUstep version and compiler is necessary?
Relatively recent GNUstep base, clang 2.7 or later (i.e. any version of clang
that's ever shipped).
The only runtime function required is the one that then calls back to GNUstep
to throw an exception. This is implemented in both libobjc2 and in the
ObjectiveC2 compatibility framework, so there is no requirement to use a
specific libobjc.
> * To get to the nub of the issue, what nasty #ifing do I need to get my nasty
> foreach() macro to use fast enumeration if available when building for
> GNUstep? (Building with distro-standard versions of GNUstep is a higher
> priority than saving on temporary enumerators, and besides, I still support
> OS X 10.4 anyway.)
See the FOREACH() macro in étoilé, which uses fast enumeration if available, or
iterators if not. Also see the macro in GNUstep, which expands to the same
thing as the for..in loop.
David
- Re: Fast enumeration, (continued)
- Re: Fast enumeration, Dr. H. Nikolaus Schaller, 2011/02/07
- Re: Fast enumeration, Jens Ayton, 2011/02/07
- Re: Fast enumeration, Dr. H. Nikolaus Schaller, 2011/02/07
- Re: Fast enumeration, Riccardo Mottola, 2011/02/09
- Re: Fast enumeration, David Chisnall, 2011/02/09
- Re: Fast enumeration, Fred Kiefer, 2011/02/09
- Re: Fast enumeration, Jens Ayton, 2011/02/09
- Re: Fast enumeration, David Chisnall, 2011/02/07
- Re: Fast enumeration, Fred Kiefer, 2011/02/07
- Re: Fast enumeration, Ivan Vučica, 2011/02/04
Re: Fast enumeration,
David Chisnall <=