[erlang-questions] Funargs: Ruby-like blocks for Erlang

Robert Virding robert.virding@REDACTED
Mon Jul 25 00:02:57 CEST 2011


I can't remember when it was added. We/some-of-use/me thought it wood be a Good Thing so I added it to the reserved words, although we never got around to adding it. Not everyone was convinced. For info 'cond' is also a reserved word, another good idea we never got around to adding. :-) I have an extended 'cond' in LFE (can do pattern matching as a test) and it is useful. 

Robert 

----- Original Message -----

> On 22 jul 2011, at 20:35, Tristan Sloughter wrote:

> > I think everyone has suggested let bindings at some point in time
> > for
> > Erlang :)
> 

> 'let' has been a 'reserved' word since at least 1998. I could not
> find any trace of it in the sources from 1994.
> Maybe robert knows more about when this was first planned for ? And
> why it was never introduced :-)

> /Tony

> > On Fri, Jul 22, 2011 at 1:23 PM, Tim Watson <
> > watson.timothy@REDACTED > wrote:
> 

> > > > I very much like the idea of a proper let (or a where) and I
> > > > think
> > > > it would make variable handling clearer. Variables are handled
> > > > in
> > > > a consistent way but it is not always easy to work out what
> > > > should
> > > > happen. Most people never ave problems with this as most people
> > > > write pretty "simple" code (from the compiler point of view).
> > > > Adding local functions, which I think would be a Good Thing, in
> > > > the same way as variables are handled today would be very
> > > > confusing so some form of 'let' construct would be necessary,
> > > > at
> > > > least for them. Then we might as well have for variables as
> > > > well.
> > 
> 
> > > >
> > 
> 

> > > I like the idea of let bindings - I think someone has suggested
> > > this
> > 
> 
> > > before. It might have been Richard, although apologies if I've
> > > got
> > 
> 
> > > that wrong.
> > 
> 

> > > _______________________________________________
> > 
> 
> > > erlang-questions mailing list
> > 
> 
> > > erlang-questions@REDACTED
> > 
> 
> > > http://erlang.org/mailman/listinfo/erlang-questions
> > 
> 

> > _______________________________________________
> 
> > erlang-questions mailing list
> 
> > erlang-questions@REDACTED
> 
> > http://erlang.org/mailman/listinfo/erlang-questions
> 

> "Have run Make so many times I dunno what's installed anymore"

> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20110724/0992615e/attachment.htm>


More information about the erlang-questions mailing list