capturing (or not) mutable local variables
Neal Gafter
neal at gafter.com
Tue Nov 23 20:13:31 PST 2010
On Tue, Nov 23, 2010 at 6:39 AM, Brian Goetz <brian.goetz at oracle.com> wrote:
> >> In a parellel world, this idiom is irretrievably broken.
> >
> > I fear that such an extreme focus on concurrent programming is rather
> > unhealthy for a general-purpose language.
>
> How can you possibly (with a straight face) describe the choice to *not*
> add a
> controversial feature as being an "unhealthily extreme focus"? Seems to me
> the rhetoric in this discussion has left the realm of reality.
>
"capture of mutable variables" is not a feature. Capture of variables (i.e.
lexical scoping) is a feature. Mutable variables is a feature. The
intersection of the two is just a confluence of two orthogonal features.
Independently designing the intersection of two otherwise orthogonal
language features on the basis of use cases is a classic sign of amateur
language design.
Failure of imagination - that is, failure to make language constructs
orthogonal because you aren't quite sure how people will need to use them
together - is one of the most common and severe errors you can make in
programming language design.
<http://gafter.blogspot.com/2006/09/failure-of-imagination-in-language_17.html>
Cheers,
Neal
More information about the lambda-dev
mailing list