[Haskell-cafe] "Assignment" in do blocks?

Oleg Grenrus oleg.grenrus at iki.fi
Wed Aug 26 12:55:15 UTC 2015

It’s not re-assigment, it’s rather feature request for non-rec-let (as let in Haskell is recursive)
and some pragma to say “yes, I do shadow name on purpose"

For example

fix f = let x = f x in x -- let is recursive
niceTry f = noreclet x = f x in x -- Not in scope: ‘x’

- Oleg

> On 26 Aug 2015, at 15:34, Francesco Ariis <fa-ml at ariis.it> wrote:
> On Wed, Aug 26, 2015 at 05:55:45PM +0530, Anupam Jain wrote:
>> Hi all,
>> I'd like to propose an inbuilt "assignment" operator for use within
>> do-blocks.
> Time to add your proposal here!
> https://wiki.haskell.org/Nitpicks
> Honestly, I feel it would break the way I read Haskell programs
> (i.e. no reassignment surprises).
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20150826/d0db2029/attachment.sig>

More information about the Haskell-Cafe mailing list