<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Objective-C 3.0</title>
	<atom:link href="http://www.losingfight.com/blog/2006/10/25/objective-c-30/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/</link>
	<description>smarter than your average squirrel, on most non-acorn related topics</description>
	<pubDate>Mon, 08 Sep 2008 06:59:23 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
		<item>
		<title>By: tyler</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-24911</link>
		<dc:creator>tyler</dc:creator>
		<pubDate>Sat, 20 Oct 2007 04:45:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-24911</guid>
		<description>http://developer.apple.com/documentation/Cocoa/Reference/ObjCRuntimeRef/Reference/reference.html#//apple_ref/c/func/objc_addClass

note comment in the sample code:

    // Allocate empty method lists.
    // We can add methods later.
    //</description>
		<content:encoded><![CDATA[<p><a href="http://developer.apple.com/documentation/Cocoa/Reference/ObjCRuntimeRef/Reference/reference.html#//apple_ref/c/func/objc_addClass" rel="nofollow">http://developer.apple.com/documentation/Cocoa/Reference/ObjCRuntimeRef/Reference/reference.html#//apple_ref/c/func/objc_addClass</a></p>
<p>note comment in the sample code:</p>
<p>    // Allocate empty method lists.<br />
    // We can add methods later.<br />
    //</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Aufflick</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-14003</link>
		<dc:creator>Mark Aufflick</dc:creator>
		<pubDate>Wed, 25 Apr 2007 13:37:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-14003</guid>
		<description>Closures would be hard in Objective-C because it's still, at its core, C. C uses a stack for holding the contexts of the chain of function calls and so has no way to 'hang on to' the context for a closure after the parent function has returned.

There is an excellent message on comp.lang.objective-c that explains this better:

http://groups.google.com/group/comp.lang.objective-c/msg/37b994ca69cde086

Certainly not impossible, but a whole lot of changing at the core of the language would be required.</description>
		<content:encoded><![CDATA[<p>Closures would be hard in Objective-C because it&#8217;s still, at its core, C. C uses a stack for holding the contexts of the chain of function calls and so has no way to &#8216;hang on to&#8217; the context for a closure after the parent function has returned.</p>
<p>There is an excellent message on comp.lang.objective-c that explains this better:</p>
<p><a href="http://groups.google.com/group/comp.lang.objective-c/msg/37b994ca69cde086" rel="nofollow">http://groups.google.com/group/comp.lang.objective-c/msg/37b994ca69cde086</a></p>
<p>Certainly not impossible, but a whole lot of changing at the core of the language would be required.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-668</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Thu, 26 Oct 2006 17:45:08 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-668</guid>
		<description>Hey Scott,

That's great info, I didn't know you could actually add a single method dynamically. It does futher my belief that what I've proposed is feasible. I was worried about my hand-waving when it came to calling anonymous functions.

However, it's still not as cool as closures. :-)</description>
		<content:encoded><![CDATA[<p>Hey Scott,</p>
<p>That&#8217;s great info, I didn&#8217;t know you could actually add a single method dynamically. It does futher my belief that what I&#8217;ve proposed is feasible. I was worried about my hand-waving when it came to calling anonymous functions.</p>
<p>However, it&#8217;s still not as cool as closures. <img src='http://www.losingfight.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-667</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Thu, 26 Oct 2006 17:41:25 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-667</guid>
		<description>Hey Joachim,

After writing this article I was convinced that closures are completely doable in Objective-C, albeit with the couple of gotchas that I outlined. I even started wondering if I should download the source to gcc and start tinkering. :-)

It would be interesting if someone smarter than I could comment on if I totally missed the boat, and suggested something that's not implementable.</description>
		<content:encoded><![CDATA[<p>Hey Joachim,</p>
<p>After writing this article I was convinced that closures are completely doable in Objective-C, albeit with the couple of gotchas that I outlined. I even started wondering if I should download the source to gcc and start tinkering. <img src='http://www.losingfight.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>It would be interesting if someone smarter than I could comment on if I totally missed the boat, and suggested something that&#8217;s not implementable.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-666</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Thu, 26 Oct 2006 17:37:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-666</guid>
		<description>Hey Keith,

You're right about fast array enumeration being in Objective-C 2.0. My choice of examples for closures probably wasn't the best one. Fortunately there are lots of better examples of the power of closures out on the web.</description>
		<content:encoded><![CDATA[<p>Hey Keith,</p>
<p>You&#8217;re right about fast array enumeration being in Objective-C 2.0. My choice of examples for closures probably wasn&#8217;t the best one. Fortunately there are lots of better examples of the power of closures out on the web.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Keith Duncan</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-664</link>
		<dc:creator>Keith Duncan</dc:creator>
		<pubDate>Thu, 26 Oct 2006 11:57:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-664</guid>
		<description>Yeah I think I missed the point of what you were saying when I read it this morning, I was mulling it over in my head durning my driving lesson (the instructor was less than pleased with my concentration) and now see what your getting at - a driving lesson evey day for a week can really tire you out!</description>
		<content:encoded><![CDATA[<p>Yeah I think I missed the point of what you were saying when I read it this morning, I was mulling it over in my head durning my driving lesson (the instructor was less than pleased with my concentration) and now see what your getting at - a driving lesson evey day for a week can really tire you out!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joachim Bengtsson</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-663</link>
		<dc:creator>Joachim Bengtsson</dc:creator>
		<pubDate>Thu, 26 Oct 2006 09:12:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-663</guid>
		<description>Closures in a compiled language would be beyond awesome (although I'd guess it's already been done by some language long forgotten...). And with a real syntax, yes please! Not all the mess with "Define a function in the global scope, get a function pointer from that, and inject that into the runtime"...

However, perhaps all that's needed is a preprocessor... ;) Next summer project here I come! (It's funny that Objc started as a preprocessor...) Although that wouldn't preserve locals, hmm...</description>
		<content:encoded><![CDATA[<p>Closures in a compiled language would be beyond awesome (although I&#8217;d guess it&#8217;s already been done by some language long forgotten&#8230;). And with a real syntax, yes please! Not all the mess with &#8220;Define a function in the global scope, get a function pointer from that, and inject that into the runtime&#8221;&#8230;</p>
<p>However, perhaps all that&#8217;s needed is a preprocessor&#8230; <img src='http://www.losingfight.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> Next summer project here I come! (It&#8217;s funny that Objc started as a preprocessor&#8230;) Although that wouldn&#8217;t preserve locals, hmm&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Scott Stevenson</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-662</link>
		<dc:creator>Scott Stevenson</dc:creator>
		<pubDate>Thu, 26 Oct 2006 08:58:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-662</guid>
		<description>The future is here now. Categories can load at runtime, and you can also &lt;a href="http://theocacao.com/document.page/327" rel="nofollow"&gt;add methods at runtime&lt;/a&gt;. You do have to get your hands messy, though.

Great post, though.</description>
		<content:encoded><![CDATA[<p>The future is here now. Categories can load at runtime, and you can also <a href="http://theocacao.com/document.page/327" rel="nofollow">add methods at runtime</a>. You do have to get your hands messy, though.</p>
<p>Great post, though.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Keith Duncan</title>
		<link>http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-661</link>
		<dc:creator>Keith Duncan</dc:creator>
		<pubDate>Thu, 26 Oct 2006 08:03:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.losingfight.com/blog/2006/10/25/objective-c-30/#comment-661</guid>
		<description>Just a little note on the closures you mention, if you read the web documentation on Obj-C 2.0 it features fast enumeration - faster than an NSEnumberator. So unless im missing something this already covered this in version two by using for(id someObject in array) NSLog(@"%@", [someObject description]);</description>
		<content:encoded><![CDATA[<p>Just a little note on the closures you mention, if you read the web documentation on Obj-C 2.0 it features fast enumeration - faster than an NSEnumberator. So unless im missing something this already covered this in version two by using for(id someObject in array) NSLog(@&#8221;%@&#8221;, [someObject description]);</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.528 seconds -->
