Dustin Getz on 23 Aug 2012 11:16:16 -0700


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: The case against call/cc


they're unrelated; immutable data is nice because mutable data is a major cause of bugs and complexity; call/cc is a low level control-flow mechanism that can be used to implement things like exceptions, generators, coroutines.

as to the paper, there is a spectrum of language design about whether a feature should be included in a language. the python and java design principles are "don't provide programmers the power to shoot themselves in the foot". as to Clojure's design principle i'm reminded of a Rich Hickey quote "[Clojure] respects the programmer’s right to do whatever they please"[1]. i might be taking his quote out of context, you can read the full context below. I think call/cc fits with clojure if the JVM could support it. it's not like you have to make it a particularly prominent; you can totally influence which language features people prefer with syntax, e.g. the way Clojure encourages immutable values over mutation without precluding mutation in warranted cases.

[1] http://www.dustingetz.com/2012/03/18/hickey-clojure-language-opinions.html

On Thu, Aug 23, 2012 at 7:36 AM, Sean Devlin <francoisdevlin@gmail.com> wrote:
I've never seen the appeal of call/cc, because it's my understanding that you can get most of the same benefits using immutable data structures (e.g. Clojure). Is this right, or am I confusing unrelated topics?

Sean Devlin

On Aug 22, 2012, at 8:55 PM, "Lalish-Menagh, Trevor" <trev@trevmex.com> wrote:

> Hi all,
>
> I thought that since we are all continuation junkies here, we might
> find this interesting:
> http://okmij.org/ftp/continuations/against-callcc.html
>
> The article argues that call/cc is a bad core feature for a language
> (if you are designing a language), and claims that it is even worse
> that goto.
>
> In any case, it is an interesting read.
>
> Yours,
> Trevor
> --
> Trevor Lalish-Menagh
> trev@trevmex.com
> 484.868.6150 (mobile)
> trevmex (AIM)