Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Curl programming language

Name: Anonymous 2010-06-06 11:12

Hey /prog/,

have you done anything in Curl (http://en.wikipedia.org/wiki/Curl_%28programming_language%29)? If so, is it any good? It looks kind of Lispy, and is attached to an apparently pretty decent RIA platform.

For those who have never heard of it, here's, some variations of factorial as code samples:

{define-proc {factorial n}
    {return {if n < 2
             then 1
             else n * {factorial (n - 1)}}}}

{define-proc {factorial n}
    {let result = 1}
    {for i = 2 to n do
        {set result = i * result}}
    {return result}}

{define-proc {factorial n}
    {let loop = {proc {acc, n}
                    {return {if n < 2
                             then acc
                             else {loop acc * n, n - 1}}}}}
    {return {loop 1, n}}}

Name: Anonymous 2010-06-06 12:32

That's like an uglier SexpCode.

Name: Anonymous 2010-06-06 12:56

>>1
Bloated sexps with braces instead of parens? Return statement? You've got to be kidding.

Name: Anonymous 2010-06-06 15:44

Pro version is available which provides additional enterprise class capabilities.

Name: Anonymous 2010-06-06 20:36

Curly braces (or ``faggot braces'') are the ugliest characters in the ascii character set. Why couldn't they have used curvy, sexy parens?

Name: Anonymous 2010-06-06 22:34

They could have at least used square brackets, which don't require the shift key to type on non-gay keyboard layouts.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List