<?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: Code Read 9 - John Backus and Functional Programming</title>
	<atom:link href="http://www.upayasoftware.com/2007/04/29/code-read-9-john-backus-and-functional-programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.upayasoftware.com/2007/04/29/code-read-9-john-backus-and-functional-programming/</link>
	<description>Looking for the skillful techniques which make it easier to build software well</description>
	<pubDate>Fri, 21 Nov 2008 04:45:40 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.3</generator>
		<item>
		<title>By: Andrew Sacamano</title>
		<link>http://www.upayasoftware.com/2007/04/29/code-read-9-john-backus-and-functional-programming/#comment-3</link>
		<dc:creator>Andrew Sacamano</dc:creator>
		<pubDate>Wed, 02 May 2007 11:06:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.upayasoftware.com/?p=16#comment-3</guid>
		<description>Thanks for the feedback, Weave Jester.  You make some very important points, particularly about testing.  And I whole-heartedly agree with you that side-effect free programming is the most important idea to come out of FP, and is now generally accepted to be one of, if not the most important, distinguishing ideas of FP.  Like you say, "there are considerable advantages to building software in a language that is entirely free of side effects."&lt;br/&gt;&lt;br/&gt;But in Backus's paper, side-effect free programming was a definite tangent - his primary argument  was that FP was more expressive and conceptually clearer than imperative programming (VNP).&lt;br/&gt;&lt;br/&gt;And FP is not the only side-effect minimizing tool.  Another style of programming that encourages side-effect free code (but is even less popular than FP) is dataflow programming - look at Prograph, for example.&lt;br/&gt;&lt;br/&gt;Lastly, in terms of efficiency, I'm still not convinced.  Call by reference, which inherently produces side effects, is a significant performance advantage.  It may be possible for skilled FP coders to work around that issue, but I'm not sure. Convince me, somebody...</description>
		<content:encoded><![CDATA[<p>Thanks for the feedback, Weave Jester.  You make some very important points, particularly about testing.  And I whole-heartedly agree with you that side-effect free programming is the most important idea to come out of FP, and is now generally accepted to be one of, if not the most important, distinguishing ideas of FP.  Like you say, &#8220;there are considerable advantages to building software in a language that is entirely free of side effects.&#8221;</p>
<p>But in Backus&#8217;s paper, side-effect free programming was a definite tangent - his primary argument  was that FP was more expressive and conceptually clearer than imperative programming (VNP).</p>
<p>And FP is not the only side-effect minimizing tool.  Another style of programming that encourages side-effect free code (but is even less popular than FP) is dataflow programming - look at Prograph, for example.</p>
<p>Lastly, in terms of efficiency, I&#8217;m still not convinced.  Call by reference, which inherently produces side effects, is a significant performance advantage.  It may be possible for skilled FP coders to work around that issue, but I&#8217;m not sure. Convince me, somebody&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Weave Jester</title>
		<link>http://www.upayasoftware.com/2007/04/29/code-read-9-john-backus-and-functional-programming/#comment-2</link>
		<dc:creator>Weave Jester</dc:creator>
		<pubDate>Mon, 30 Apr 2007 11:36:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.upayasoftware.com/?p=16#comment-2</guid>
		<description>The primary difference, in my opinion, of functional programming compared to more traditional imperative methods, is its attempt to minimise side effects. The more side effects are done away with, the more 'functional' a language is. If there are no side effects whatsoever, then the language is purely functional. The elimination of side effects is not, itself, a side effect - it's one of the basic principles by which FP is defined.&lt;br/&gt;&lt;br/&gt;A lack of side effects is not only useful for parallel programming; it's also useful for testing and reliability. You can unit test a pure function however much you want, safe in the knowledge that for any argument x, you'll always get the same return value, y. You can also be sure it won't inadvertently change your system in any way.&lt;br/&gt;&lt;br/&gt;Combined with a robust type system, you have further opportunities to check your program is correct. Since all effects of a function must occur through its return value, this means all the effects of a function must also be typed. A type system in a purely functional language is more pervasive than one in an imperative language can be.&lt;br/&gt;&lt;br/&gt;Regarding efficiency, pure functional languages are not significantly any less efficient than their imperative equivalents in most cases. Certainly the difference is much smaller than the difference between, say, C++ and C#.&lt;br/&gt;&lt;br/&gt;Whilst FP languages can be hard to read and understand, I'm not certain that has to be the case. And even if that is the case, I don't think a programming language has ever died from being too complex :). Maybe pure FP will never be mainstream, but I don't think it will disappear, either; there are considerable advantages to building software in a language that is entirely free of side effects.</description>
		<content:encoded><![CDATA[<p>The primary difference, in my opinion, of functional programming compared to more traditional imperative methods, is its attempt to minimise side effects. The more side effects are done away with, the more &#8216;functional&#8217; a language is. If there are no side effects whatsoever, then the language is purely functional. The elimination of side effects is not, itself, a side effect - it&#8217;s one of the basic principles by which FP is defined.</p>
<p>A lack of side effects is not only useful for parallel programming; it&#8217;s also useful for testing and reliability. You can unit test a pure function however much you want, safe in the knowledge that for any argument x, you&#8217;ll always get the same return value, y. You can also be sure it won&#8217;t inadvertently change your system in any way.</p>
<p>Combined with a robust type system, you have further opportunities to check your program is correct. Since all effects of a function must occur through its return value, this means all the effects of a function must also be typed. A type system in a purely functional language is more pervasive than one in an imperative language can be.</p>
<p>Regarding efficiency, pure functional languages are not significantly any less efficient than their imperative equivalents in most cases. Certainly the difference is much smaller than the difference between, say, C++ and C#.</p>
<p>Whilst FP languages can be hard to read and understand, I&#8217;m not certain that has to be the case. And even if that is the case, I don&#8217;t think a programming language has ever died from being too complex :). Maybe pure FP will never be mainstream, but I don&#8217;t think it will disappear, either; there are considerable advantages to building software in a language that is entirely free of side effects.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
