Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-09 Thread Colin Fleming
True, but I think that's why he argues for a strict language which controls
side effects via monads, as Haskell does.


On 9 July 2014 07:18, Magnus Therning  wrote:

> On Tue, Jul 08, 2014 at 08:39:30PM +0200, Colin Fleming wrote:
> > I searched for this as well, and found this:
> > http://www.cs.nott.ac.uk/~gmh/appsem-slides/peytonjones.ppt
> >
> > "Purity is more important than, and quite independent of, laziness"
> >
> > and
> >
> > "The next ML will be pure, with effects only via monads.  The next
> Haskell
> > will be strict, but still pure."
>
> In the same presentation he also says that laziness has forced Haskell
> to stay pure, and that
>
> "Every call-by-value language has given into the siren call of side
> effects."
>
> So even if they are independent on the technical level one could say
> that they are dependent on a design/social level.
>
> /M
>
> --
> Magnus Therning  OpenPGP: 0xAB4DFBA4
> email: mag...@therning.org   jabber: mag...@therning.org
> twitter: magthe   http://therning.org/magnus
>
> Most software today is very much like an Egyptian pyramid with
> millions of bricks piled on top of each other, with no structural
> integrity, but just done by brute force and thousands of slaves.
>  -- Alan Kay
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Magnus Therning
On Tue, Jul 08, 2014 at 08:39:30PM +0200, Colin Fleming wrote:
> I searched for this as well, and found this:
> http://www.cs.nott.ac.uk/~gmh/appsem-slides/peytonjones.ppt
> 
> "Purity is more important than, and quite independent of, laziness"
> 
> and
> 
> "The next ML will be pure, with effects only via monads.  The next Haskell
> will be strict, but still pure."

In the same presentation he also says that laziness has forced Haskell
to stay pure, and that

"Every call-by-value language has given into the siren call of side
effects."

So even if they are independent on the technical level one could say
that they are dependent on a design/social level.

/M

-- 
Magnus Therning  OpenPGP: 0xAB4DFBA4 
email: mag...@therning.org   jabber: mag...@therning.org
twitter: magthe   http://therning.org/magnus

Most software today is very much like an Egyptian pyramid with
millions of bricks piled on top of each other, with no structural
integrity, but just done by brute force and thousands of slaves.
 -- Alan Kay


pgpya0QpHNyf9.pgp
Description: PGP signature


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Colin Fleming
I searched for this as well, and found this:
http://www.cs.nott.ac.uk/~gmh/appsem-slides/peytonjones.ppt

"Purity is more important than, and quite independent of, laziness"

and

"The next ML will be pure, with effects only via monads.  The next Haskell
will be strict, but still pure."


On 8 July 2014 19:58, Andrey Antukh  wrote:

> 2014-07-08 18:20 GMT+02:00 Marko Kocić :
>
> Clojure doesn't have lazy evaluation because it is a "few" years younger
>> and didn't want to repeat Haskell's mistake. Even Simon Payton Jones, the
>> creator of Haskel, confessed that, if he would make Haskel again, he would
>> make it strict, and not lazy, but that it's too late to change it.
>>
>> --
>>
>
> Sorry for offtopic, but, you have source of it?
>
> Andrey
>
>
>>  You received this message because you are subscribed to the Google
>> Groups "Clojure" group.
>> To post to this group, send email to clojure@googlegroups.com
>> Note that posts from new members are moderated - please be patient with
>> your first post.
>> To unsubscribe from this group, send email to
>> clojure+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/clojure?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "Clojure" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to clojure+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Andrey Antukh - Андрей Антух -  / <
> n...@niwi.be>
> http://www.niwi.be 
> https://github.com/niwibe
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Andrey Antukh
2014-07-08 18:20 GMT+02:00 Marko Kocić :

> Clojure doesn't have lazy evaluation because it is a "few" years younger
> and didn't want to repeat Haskell's mistake. Even Simon Payton Jones, the
> creator of Haskel, confessed that, if he would make Haskel again, he would
> make it strict, and not lazy, but that it's too late to change it.
>
> --
>

Sorry for offtopic, but, you have source of it?

Andrey


> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Andrey Antukh - Андрей Антух -  / 
http://www.niwi.be 
https://github.com/niwibe

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Marko Kocić
Clojure doesn't have lazy evaluation because it is a "few" years younger 
and didn't want to repeat Haskell's mistake. Even Simon Payton Jones, the 
creator of Haskel, confessed that, if he would make Haskel again, he would 
make it strict, and not lazy, but that it's too late to change it.

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread James Reeves
Laziness is a useful property, but it is not without its disadvantages,
particularly in terms of predictable performance. For example, code
involving lazy seqs is more prone to memory leaks than iterators are.

Eager evaluation is a simpler approach, in terms of both code and
predictability. Eager evaluation fails fast, and has predictable
performance characteristics. Laziness is a useful tool to have in one's
arsenal, but I don't believe it should be the norm, as most of the time
it's not necessary.

Of course, most Haskell users would probably disagree with me :)

- James



On 8 July 2014 14:13, Ashish Negi  wrote:

> I am new to clojure and finding it great.. :)
>
> I came across a paper - Why functional programming matters ?
> at www.cs.kent.ac.uk/people/staff/dat/miranda/whyfp90.pdf
>
>
>
> to quote it :
> "This paper is also relevant to the present controversy over lazy
> evaluation.
> Some believe that functional languages should be lazy; others believe they
> should not. Some compromise and provide only lazy lists, with a special
> syntax
> for constructing them (as, for example, in Scheme [1]). This paper provides
> further evidence that lazy evaluation is too important to be relegated to
> *secondclasscitizenship*. It is perhaps the most powerful glue functional
> programmers
> possess. One should not obstruct access to such a vital tool."
>
> I know that if you people have taken some important decision for clojure,
> it must had been after some thoughts.
>
> Was it difficult to implement or not that good ?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Zach Oakes
Abstract topics like this are interesting, but you may be better off 
starting a discussion at a more generic venue like /r/programming, because 
it isn't really specific to Clojure. I would assume that pervasive laziness 
would greatly complicate interop with hosts like the JVM.

On Tuesday, July 8, 2014 9:13:56 AM UTC-4, Ashish Negi wrote:
>
> I am new to clojure and finding it great.. :)
>
> I came across a paper - Why functional programming matters ?
> at www.cs.kent.ac.uk/people/staff/dat/miranda/whyfp90.pdf
>
>
>
> to quote it :
> "This paper is also relevant to the present controversy over lazy 
> evaluation.
> Some believe that functional languages should be lazy; others believe they
> should not. Some compromise and provide only lazy lists, with a special 
> syntax
> for constructing them (as, for example, in Scheme [1]). This paper provides
> further evidence that lazy evaluation is too important to be relegated to 
> *secondclasscitizenship*. It is perhaps the most powerful glue functional 
> programmers
> possess. One should not obstruct access to such a vital tool."
>
> I know that if you people have taken some important decision for clojure, 
> it must had been after some thoughts.
>
> Was it difficult to implement or not that good ?
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Why clojure does not have pure lazy-evaluation like Haskell ?

2014-07-08 Thread Ashish Negi
I am new to clojure and finding it great.. :)

I came across a paper - Why functional programming matters ?
at www.cs.kent.ac.uk/people/staff/dat/miranda/whyfp90.pdf



to quote it :
"This paper is also relevant to the present controversy over lazy 
evaluation.
Some believe that functional languages should be lazy; others believe they
should not. Some compromise and provide only lazy lists, with a special 
syntax
for constructing them (as, for example, in Scheme [1]). This paper provides
further evidence that lazy evaluation is too important to be relegated to 
*secondclasscitizenship*. It is perhaps the most powerful glue functional 
programmers
possess. One should not obstruct access to such a vital tool."

I know that if you people have taken some important decision for clojure, 
it must had been after some thoughts.

Was it difficult to implement or not that good ?

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.