On 10 Aug 2007, at 6:42 am, David Roundy wrote:
do x1 <- e1
if x1 then do x2 <- e2
xx <- if x2 then e3
else do x4 <- e4
x5 <- e5
e6 x4 x5
e7 xx x1
e
On Thu, Aug 09, 2007 at 11:52:17AM -0700, David Roundy wrote:
> On Thu, Aug 09, 2007 at 02:08:20PM +0100, Jules Bean wrote:
*snip*
> > A third example is with nested dos:
> >
> > do x <- bar y
> >baz
> >something $ do foo x
> >
> > is not the same as
> >
> > do baz
> >something $
On Thu, Aug 09, 2007 at 02:08:20PM +0100, Jules Bean wrote:
> David Roundy wrote:
> >On Wed, Aug 08, 2007 at 02:20:39PM -0400, Paul Hudak wrote:
> >As long as the sugar has a pretty obvious desugaring (which I seem to
> >recall it did), I don't see how it's likely to make things worse. And
>
> So
On Thu, Aug 09, 2007 at 04:02:05PM +1200, ok wrote:
> On 9 Aug 2007, at 8:41 am, David Roundy wrote:
> >I may be stating the obvious here, but I strongly prefer the do syntax.
> >It's nice to know the other also, but the combination of do +indenting
> >makes complicated code much clearer than the n
For what it's worth from a Haskell newbie (and from someone who's been doing
FP since November, mainly in Scala.)
I really like Haskell's purity and having the clear separation between zero
side effects and monads is most excellent.
It was quite a brain change to program functionally. It took a
David Roundy wrote:
On Wed, Aug 08, 2007 at 02:20:39PM -0400, Paul Hudak wrote:
As long as the sugar has a pretty obvious desugaring (which I seem to
recall it did), I don't see how it's likely to make things worse. And
Some people are arguing that the desugaring isn't obvious.
Although I lik
Hello Paul,
Wednesday, August 8, 2007, 10:20:39 PM, you wrote:
> we need). On the other hand, if we give imperative programmers the
> tools to do all the things they are used to doing in C++, then we
> will be depriving them of the joys of programming in the Functional
> Way. How many times hav
On 8/9/07, ok <[EMAIL PROTECTED]> wrote:
>
> We get extra >>, >>=, \, ->, and "in" tokens, but no new parentheses.
>
Yes exactly. It's the >>= and >> that gets rid of the parentheses, and
reverses the order of the operations.
I cant remember where I saw this, but somewhere there is a monad tutor
On 9 Aug 2007, at 8:41 am, David Roundy wrote:
I may be stating the obvious here, but I strongly prefer the do
syntax.
It's nice to know the other also, but the combination of do
+indenting makes
complicated code much clearer than the nested parentheses that
would be
required with purely >>=
bf3:
>
>IMHO and being a newbie having 20 years of professional
>C/C++/C# experience but hardly any Haskell experience, I
>agree with this... I find the monad syntax very confusing,
>because it looks so much like imperative code, but it isn't.
>Personally I also liked the Concu
I can't agree with your point about Haskell being (just) a prototype language (assuming that's what
you meant). If that's the case, it won't last very long. Languages need to be something you can
write real, practical applications in. Fortunately, Haskell isn't just a prototype language. I'm
Paul Hudak wrote:
All of the recent talk of support for imperative programming in
Haskell makes me really nervous
... if we give imperative programmers the tools to do all the things
they are used to doing in C++, then we will be depriving them of the
joys of programming in the Functional
On Wed, Aug 08, 2007 at 02:20:39PM -0400, Paul Hudak wrote:
> All of the recent talk of support for imperative programming in Haskell
> makes me really nervous. To be honest, I've always been a bit
> uncomfortable even with monad syntax. Instead of:
>
> do x <- cmd1
> y <- cmd2
> ...
>
On 8/9/07, peterv <[EMAIL PROTECTED]> wrote:
>
> IMHO and being a newbie having 20 years of professional C/C++/C#
> experience but hardly any Haskell experience, I agree with this… I find the
> monad syntax very confusing, because it looks so much like imperative code,
> but it isn't. Personally I
On Wed, 8 Aug 2007, Paul Hudak wrote:
...
> Well, you could argue, monad syntax is what really made Haskell become
> more accepted by the masses, and you may be right (although perhaps
> Simon's extraordinary performance at OSCOM is more of what we need). On
> the other hand, if we give imperat
On 8/8/07, Philippa Cowderoy <[EMAIL PROTECTED]> wrote:
>
> On Wed, 8 Aug 2007, peterv wrote:
> {...
> An editor that can be configured to display various inferred details,
> annotations and desugarings in the middle of the source would be useful
> for all kinds of purposes, and certainly not just
On Wed, 8 Aug 2007, peterv wrote:
> PS: It would be very nice for beginners to have a special tool / text editor
> that allows you see the desugared form of monads and other constructs.
>
An editor that can be configured to display various inferred details,
annotations and desugarings in the mi
m of monads and other constructs.
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Hudak
Sent: Wednesday, August 08, 2007 8:21 PM
To: haskell-cafe@haskell.org
Cc: [EMAIL PROTECTED]
Subject: [Haskell-cafe] a regressive view of support for imperative
programming in Haskell
All
All of the recent talk of support for imperative programming in Haskell
makes me really nervous. To be honest, I've always been a bit
uncomfortable even with monad syntax. Instead of:
do x <- cmd1
y <- cmd2
...
return e
I was always perfectly happy with:
cmd1 >>= \x->
cmd2 >>= \
19 matches
Mail list logo