[Erlang Forums] [Erlang/OTP Proposals/Proposals: RFC] Re-visiting EEP-0055

Raimo Niskanen raimo+erlang-questions@REDACTED
Fri Apr 29 00:47:04 CEST 2022


On Fri, Apr 29, 2022 at 12:00:39AM +1200, Richard O'Keefe wrote:
> I can't recall everything I said against this EEP,
> but there are two issues I can think of right now,
> and a better alternative.
:
> The counter-proposal is quite simple.
:
> (B) Fix the locality problem.  The right way.
>     By declaring which variables are *local*,
>     not which variables are *not* local.
>     Borrowing some syntax from Prolog (as Erlang
>     originally got its syntax thence), let D be
>     a syntactic form made of tuples, lists, and
>     variables, and C be a pattern or expression.
>     Then D ^ C means that each of the variables
>     in D represents a new variable in C, not
>     provided, visible, or in any way accessible
>     in C.
> 
> With this approach, local scope is available for
> *every* construct.  With the scope marker being
> located at the *beginning* of a construct, instead
> of being buried possibly deeply inside, it should
> be easier to read.
> 

Could you show a small example?
I do not realize what this would look like...

Cheers
-- 

/ Raimo Niskanen, Erlang/OTP, Ericsson AB


More information about the erlang-questions mailing list