<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/'><id>tag:blogger.com,1999:blog-11295132.post4790015581908022633..comments</id><updated>2009-11-29T19:32:41.103-08:00</updated><title type='text'>Comments on A Neighborhood of Infinity: Purely functional recursive types in Haskell and P...</title><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://blog.sigfpe.com/feeds/4790015581908022633/comments/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html'/><author><name>sigfpe</name><uri>http://www.blogger.com/profile/08096190433222340957</uri><email>noreply@blogger.com</email></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>10</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-11295132.post-1666956632141526809</id><published>2009-11-29T19:06:39.190-08:00</published><updated>2009-11-29T19:06:39.190-08:00</updated><title type='text'>sigfpe--

Aaaugh, scary but interesting post!  How...</title><content type='html'>sigfpe--&lt;br /&gt;&lt;br /&gt;Aaaugh, scary but interesting post!  However, the problem discussed there&lt;br /&gt;* isn&amp;#39;t with lambdas per se,&lt;br /&gt;* it&amp;#39;s with a closure (lambda &lt;i&gt;or&lt;/i&gt; def) referring to loop variables in the enclosing function&lt;br /&gt;* so doing the closure with def doesn&amp;#39;t change that situation&lt;br /&gt;* anyway it doesn&amp;#39;t come up in your situation (referring to the enclosing function&amp;#39;s parameters)&lt;br /&gt;&lt;br /&gt;My sense even after that post is that Python&amp;#39;s closures are about as pure or impure as Scheme&amp;#39;s (unless you think of the tail-call memory leak as impurity).&lt;br /&gt;&lt;br /&gt;Apply paranoias sparingly!</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/1666956632141526809'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/1666956632141526809'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1259550399190#c1666956632141526809' title=''/><author><name>FutureNerd</name><uri>http://www.blogger.com/profile/17103481765366134475</uri><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-6517898903534368590</id><published>2009-11-29T14:36:26.967-08:00</published><updated>2009-11-29T14:36:26.967-08:00</updated><title type='text'>FutureNerd,

Can't remember why I didn't use lambd...</title><content type='html'>FutureNerd,&lt;br /&gt;&lt;br /&gt;Can&amp;#39;t remember why I didn&amp;#39;t use lambdas. Probably the sort of paranoia expressed here: http://math.andrej.com/2009/04/09/pythons-lambda-is-broken/</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/6517898903534368590'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/6517898903534368590'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1259534186967#c6517898903534368590' title=''/><author><name>sigfpe</name><uri>http://www.blogger.com/profile/08096190433222340957</uri><email>noreply@blogger.com</email><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='OpenSocialUserId' value='09401818062305273147'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-957866450244527130</id><published>2009-11-29T13:48:43.699-08:00</published><updated>2009-11-29T13:48:43.699-08:00</updated><title type='text'>"""
(I'm leaving a comment, heh.)

I thought a cou...</title><content type='html'>&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;(I&amp;#39;m leaving a &lt;i&gt;comment,&lt;/i&gt; heh.)&lt;br /&gt;&lt;br /&gt;I thought a couple of your examples would have been clearer by first saying&lt;br /&gt;&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;def plus(a,b):&lt;br /&gt;____return a+b&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;&lt;br /&gt;(Wanting Python to have a syntax for that is the kind of pressure that created C++!)&lt;br /&gt;&lt;br /&gt;Funny omission...&lt;br /&gt;&lt;br /&gt;&lt;i&gt;...each constructor is replaced with the appropriate function. Here&amp;#39;s an example:&lt;br /&gt;&lt;br /&gt;Now consider a simple expression type in Haskell:&lt;/i&gt;&lt;br /&gt;&lt;br /&gt;...as in, &amp;quot;Wanna see me do it again?&amp;quot; or, &amp;quot;Yes, in Python it&amp;#39;s that simple!&amp;quot;  I do get the idea, though.&lt;br /&gt;&lt;br /&gt;Is there an efficiency, readability or code style reason why you use internal defs with just a return line, instead of lambdas?  I.e., (why) do you prefer&lt;br /&gt;&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;i&gt;&lt;br /&gt;def cons(h,t):&lt;br /&gt;____def _cons(a,b):&lt;br /&gt;________return a(h,t(a,b))&lt;br /&gt;____return _cons&lt;/i&gt;&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;&lt;br /&gt;to&lt;br /&gt;&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;def cons(h,t):&lt;br /&gt;____return lambda a,b: a(h,t(a,b))&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;&lt;br /&gt;?&lt;br /&gt;&lt;br /&gt;I wonder whether there&amp;#39;s a compiler somewhere that recognizes nested lambdas as conses or sequential arrays (I infer that Haskell doesn&amp;#39;t?).&lt;br /&gt;&lt;br /&gt;Interesting stuff, I got here from your &amp;quot;Programming with impossible functions.&amp;quot;&lt;br /&gt;&amp;quot;&amp;quot;&amp;quot;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/957866450244527130'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/957866450244527130'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1259531323699#c957866450244527130' title=''/><author><name>FutureNerd</name><uri>http://www.blogger.com/profile/17103481765366134475</uri><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-2628910756809651498</id><published>2009-11-29T01:53:17.186-08:00</published><updated>2009-11-29T01:53:17.186-08:00</updated><title type='text'>Minor typo: "Evaluating X, 2 and X+2 at X=2:" shou...</title><content type='html'>Minor typo: &amp;quot;Evaluating X, 2 and X+2 at X=2:&amp;quot; should be &amp;quot;Evaluating X, 2 and X+2 at X=3&amp;quot;.&lt;br /&gt;&lt;br /&gt;Thanks for the post, I enjoyed it very much.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/2628910756809651498'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/2628910756809651498'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1259488397186#c2628910756809651498' title=''/><author><name>Anonymous</name><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-393736379414453464</id><published>2008-02-11T00:55:00.000-08:00</published><updated>2008-02-11T00:55:00.000-08:00</updated><title type='text'>You say that "Wadler's paper also describes a dual...</title><content type='html'>You say that "Wadler's paper also describes a dual version of this for codata such as streams. But as far as I understand it's not very interesting." I disagree; I think the dual is very interesting! Whereas the inductive version captures &lt;I&gt;algebraic datatypes&lt;/I&gt; as purely functional recursive types, the coinductive version captures &lt;I&gt;abstract datatypes&lt;/I&gt;. I exploit this in my paper &lt;A HREF="http://web.comlab.ox.ac.uk/jeremy.gibbons/publications/#adt" REL="nofollow"&gt;&lt;I&gt;Unfolding Abstract Datatypes&lt;/I&gt;&lt;/A&gt;. (I'd explain here, but the margin is too narrow.)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/393736379414453464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/393736379414453464'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1202720100000#c393736379414453464' title=''/><author><name>Jeremy Gibbons</name><uri>http://web.comlab.ox.ac.uk/jeremy.gibbons/</uri><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-5404315802001185343</id><published>2008-02-06T18:14:00.000-08:00</published><updated>2008-02-06T18:14:00.000-08:00</updated><title type='text'>One quick point. If you want to test for an empty ...</title><content type='html'>One quick point. If you want to test for an empty list, it is better to do:&lt;BR/&gt;&lt;BR/&gt;if not l:&lt;BR/&gt;&lt;BR/&gt;instead of&lt;BR/&gt;&lt;BR/&gt;if l==[]:</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/5404315802001185343'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/5404315802001185343'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1202350440000#c5404315802001185343' title=''/><author><name>Anonymous</name><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-8578190877917464452</id><published>2008-02-04T16:31:32.439-08:00</published><updated>2008-02-04T16:31:32.439-08:00</updated><title type='text'>單中杰,In your paper I read&gt; This representation is a...</title><content type='html'>單中杰,&lt;BR/&gt;&lt;BR/&gt;In your paper I read&lt;BR/&gt;&lt;BR/&gt;&gt; This representation is almost the same as in §1.1, only written with lowercase identifiers.&lt;BR/&gt;&lt;BR/&gt;At one point I started writing exactly the same sentence when composing my blog post. I'll have to read the rest of that paper, it seems interesting.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/8578190877917464452'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/8578190877917464452'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1202171492439#c8578190877917464452' title=''/><author><name>sigfpe</name><uri>http://www.blogger.com/profile/08096190433222340957</uri><email>noreply@blogger.com</email><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='OpenSocialUserId' value='09401818062305273147'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-4181496518427162110</id><published>2008-02-04T16:20:06.911-08:00</published><updated>2008-02-04T16:20:06.911-08:00</updated><title type='text'>Mikael,Well there's already a nice description in ...</title><content type='html'>Mikael,&lt;BR/&gt;&lt;BR/&gt;Well there's already a nice description in terms of initial F-algebras but I think I see what you mean.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/4181496518427162110'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/4181496518427162110'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1202170806911#c4181496518427162110' title=''/><author><name>sigfpe</name><uri>http://www.blogger.com/profile/08096190433222340957</uri><email>noreply@blogger.com</email><gd:extendedProperty xmlns:gd='http://schemas.google.com/g/2005' name='OpenSocialUserId' value='09401818062305273147'/></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-5282066745810671307</id><published>2008-02-03T01:39:00.000-08:00</published><updated>2008-02-03T01:39:00.000-08:00</updated><title type='text'>Now I -really- want to see (or write) a discussion...</title><content type='html'>Now I -really- want to see (or write) a discussion of recursive data types and generalized folds in the language of operads! What you said a generalized fold is looks to me very much like the construction of a free operads on a set of operations. (and/or possibly representations of such)</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/5282066745810671307'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/5282066745810671307'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1202031540000#c5282066745810671307' title=''/><author><name>Mikael</name><uri>http://www.blogger.com/profile/00008302080954798496</uri><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry><entry><id>tag:blogger.com,1999:blog-11295132.post-4658616282479604294</id><published>2008-02-02T15:58:00.000-08:00</published><updated>2008-02-02T15:58:00.000-08:00</updated><title type='text'>Good post. I think what's missing is a discussion ...</title><content type='html'>Good post. I think what's missing is a discussion of the connection with lambda calculus, since all you're really describing is a couple of implementations in concrete languages of standard l-c types.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/4658616282479604294'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/11295132/4790015581908022633/comments/default/4658616282479604294'/><link rel='alternate' type='text/html' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html?showComment=1201996680000#c4658616282479604294' title=''/><author><name>suppressingfire</name><uri>http://suppressingfire.livejournal.com/</uri><email>noreply@blogger.com</email></author><thr:in-reply-to xmlns:thr='http://purl.org/syndication/thread/1.0' href='http://blog.sigfpe.com/2008/02/purely-functional-recursive-types-in.html' ref='tag:blogger.com,1999:blog-11295132.post-4790015581908022633' source='http://www.blogger.com/feeds/11295132/posts/default/4790015581908022633' type='text/html'/></entry></feed>