<?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: The state of functional programming in PHP</title>
	<atom:link href="http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/</link>
	<description>News, opinion, and fresh thinking for web developers and designers. The official podcast of sitepoint.com.</description>
	<pubDate>Tue, 02 Dec 2008 05:05:55 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
		<item>
		<title>By: 今日連結 (2008-03-26) [JeffHung.Blog]</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-687786</link>
		<dc:creator>今日連結 (2008-03-26) [JeffHung.Blog]</dc:creator>
		<pubDate>Fri, 11 Apr 2008 15:26:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-687786</guid>
		<description>[...] The state of functional programming in PHP [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] The state of functional programming in PHP [&#8230;]</p>]]></content:encoded>
	</item>
	<item>
		<title>By: kyberfabrikken</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-601603</link>
		<dc:creator>kyberfabrikken</dc:creator>
		<pubDate>Sun, 13 Jan 2008 12:26:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-601603</guid>
		<description>In case anybody wants to play around with currying in current versions of PHP, I've posted a working implementation &lt;a href="http://www.sitepoint.com/forums/showpost.php?p=3685119&#38;postcount=2" rel="nofollow"&gt;here&lt;/a&gt;. This is superior to the serializing/embedding technique, which some of the commenters to this post, have shown.</description>
		<content:encoded><![CDATA[<p>In case anybody wants to play around with currying in current versions of PHP, I&#8217;ve posted a working implementation <a href="http://www.sitepoint.com/forums/showpost.php?p=3685119&amp;postcount=2" rel="nofollow">here</a>. This is superior to the serializing/embedding technique, which some of the commenters to this post, have shown.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Eric Ritz</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-578139</link>
		<dc:creator>Eric Ritz</dc:creator>
		<pubDate>Sun, 30 Dec 2007 21:11:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-578139</guid>
		<description>&lt;a href="http://www.cybersprocket.com/wiki/index.php/Eric%27s_PHP_Guide" rel="nofollow"&gt;I've written a bit&lt;/a&gt; about functional techniques in PHP.</description>
		<content:encoded><![CDATA[<p><a href="http://www.cybersprocket.com/wiki/index.php/Eric%27s_PHP_Guide" rel="nofollow">I&#8217;ve written a bit</a> about functional techniques in PHP.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: binjured</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-569760</link>
		<dc:creator>binjured</dc:creator>
		<pubDate>Tue, 25 Dec 2007 08:44:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-569760</guid>
		<description>Bah.  Why won't people accept this is just an issue with PHP and there's no semantic fix for it?  Functions aren't first-class objects like in languages such as Python.  After living with Python for a year I have no love for PHP, but that being said I still think there's no reason to try and make it something it isn't.  If I can't do &lt;code&gt;$var = fn&lt;/code&gt; then why bother?  The kludgy workarounds aren't worth it.

PHP isn't a Functional language.  Heck, it's hardly Object-Oriented (at least before the latest 5 release).  Why try to make it that way?  If you want functional, if you want proper OO, use a better language.  Just my 2 cents.</description>
		<content:encoded><![CDATA[<p>Bah.  Why won&#8217;t people accept this is just an issue with PHP and there&#8217;s no semantic fix for it?  Functions aren&#8217;t first-class objects like in languages such as Python.  After living with Python for a year I have no love for PHP, but that being said I still think there&#8217;s no reason to try and make it something it isn&#8217;t.  If I can&#8217;t do <code>$var = fn</code> then why bother?  The kludgy workarounds aren&#8217;t worth it.</p>
<p>PHP isn&#8217;t a Functional language.  Heck, it&#8217;s hardly Object-Oriented (at least before the latest 5 release).  Why try to make it that way?  If you want functional, if you want proper OO, use a better language.  Just my 2 cents.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Newscast for 2007.12.20 &#124; PHP Podcasts</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-568038</link>
		<dc:creator>Newscast for 2007.12.20 &#124; PHP Podcasts</dc:creator>
		<pubDate>Sun, 23 Dec 2007 21:30:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-568038</guid>
		<description>[...] Closures [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] Closures [&#8230;]</p>]]></content:encoded>
	</item>
	<item>
		<title>By: SitePoint Blogs &#187; Lexical scope to appear in PHP?</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-567085</link>
		<dc:creator>SitePoint Blogs &#187; Lexical scope to appear in PHP?</dc:creator>
		<pubDate>Sun, 23 Dec 2007 02:20:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-567085</guid>
		<description>[...] mentioned briefly, in my last post, that Wez Furlong made a patch back in March, that allows a native syntax for creating anonymous [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] mentioned briefly, in my last post, that Wez Furlong made a patch back in March, that allows a native syntax for creating anonymous [&#8230;]</p>]]></content:encoded>
	</item>
	<item>
		<title>By: caiomoritz</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-566963</link>
		<dc:creator>caiomoritz</dc:creator>
		<pubDate>Sat, 22 Dec 2007 23:38:35 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-566963</guid>
		<description>Hi,

&lt;a href="http://news.php.net/php.internals/34216" rel="nofollow"&gt;This thread&lt;/a&gt; shows Christian Seiler's patch to include closures in PHP 5.3. Thought you guys would like to check that out. It was posted today.</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p><a href="http://news.php.net/php.internals/34216" rel="nofollow">This thread</a> shows Christian Seiler&#8217;s patch to include closures in PHP 5.3. Thought you guys would like to check that out. It was posted today.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: kyberfabrikken</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-560903</link>
		<dc:creator>kyberfabrikken</dc:creator>
		<pubDate>Wed, 19 Dec 2007 09:59:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-560903</guid>
		<description>Paul Meagher:
No doubt, there's a lot to be said on this topic.

ron (and nick@pixelnix.com):
You can use create_function for currying in two ways; Marshalling variables to a string and embed it, or using a global storage. My intention with this post, was not to dwell too much about implementation. The point is, that it's impractical to use, for performance reasons.</description>
		<content:encoded><![CDATA[<p>Paul Meagher:<br />
No doubt, there&#8217;s a lot to be said on this topic.</p>
<p>ron (and <a href="mailto:nick@pixelnix.com">nick@pixelnix.com</a>):<br />
You can use create_function for currying in two ways; Marshalling variables to a string and embed it, or using a global storage. My intention with this post, was not to dwell too much about implementation. The point is, that it&#8217;s impractical to use, for performance reasons.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Paul Meagher</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-560553</link>
		<dc:creator>Paul Meagher</dc:creator>
		<pubDate>Wed, 19 Dec 2007 04:07:09 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-560553</guid>
		<description>On the topic of functional programming, you might have wanted to spend a bit of time talking about the array_map, array_filter, and array_reduce functions.  These are your main tools for doing functional programming in PHP.

List comprehension is another feature that is often mentioned in the context of functional programming.  Haskell blows most other languages out of the water in terms of its implementation of this feature.

Hope you keep the functional programming tread alive in a few more posts.... would be nice to see PHP influenced more by functional programming languages rather than predominately OO langs like Java.</description>
		<content:encoded><![CDATA[<p>On the topic of functional programming, you might have wanted to spend a bit of time talking about the array_map, array_filter, and array_reduce functions.  These are your main tools for doing functional programming in PHP.</p>
<p>List comprehension is another feature that is often mentioned in the context of functional programming.  Haskell blows most other languages out of the water in terms of its implementation of this feature.</p>
<p>Hope you keep the functional programming tread alive in a few more posts&#8230;. would be nice to see PHP influenced more by functional programming languages rather than predominately OO langs like Java.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: ron</title>
		<link>http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-559610</link>
		<dc:creator>ron</dc:creator>
		<pubDate>Tue, 18 Dec 2007 16:10:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.sitepoint.com/blogs/2007/12/15/the-state-of-functional-programming-in-php/#comment-559610</guid>
		<description>The curry example function could be written quite easily with create_function:

function curry($func, $args) {
        if (!is_array($args) ) {
                $args = array($args);
        }
        return create_function("", "\$args = func_get_args(); \$args = array_merge(array(" . implode("\",\"", $args) . "), \$args); return call_user_func_array(\"$func\", \$args);");
}</description>
		<content:encoded><![CDATA[<p>The curry example function could be written quite easily with create_function:</p>
<p>function curry($func, $args) {<br />
        if (!is_array($args) ) {<br />
                $args = array($args);<br />
        }<br />
        return create_function(&#8221;", &#8220;\$args = func_get_args(); \$args = array_merge(array(&#8221; . implode(&#8221;\&#8221;,\&#8221;", $args) . &#8220;), \$args); return call_user_func_array(\&#8221;$func\&#8221;, \$args);&#8221;);<br />
}</p>]]></content:encoded>
	</item>
</channel>
</rss>
