Class method addition and replacement (was Re: AOP Compatibility)
Nathan de Vries
nathan at atnan.com
Sun Apr 6 03:06:34 PDT 2008
On 06/04/2008, at 1:38 AM, Brendan Eich wrote:
>> developers will be able to explicitly mark areas in their code which
>> they deem appropriate for another developer to change, but that
>> strikes me as a bit of a fantasy land.
> The fantasy here would be that JS has been kept down on the same-
> origin and small-scale storybook farm where it was born. It's in
> the big city now. ;-)
>> The majority of code which requires patching by external developers
>> was never written to be patched, but people do it anyway. This is
>> good, don't you agree?
> See above.
I'm not denying that the problems you're trying to fix aren't
problems, it's just that I believe a wholesale locking down of the
language will be too drastic and may result in a shift away from the
To give some context, when you speak of "producers" & "consumers" of
consumer. You may be surprised to hear that mutability is one of the
things that I love about the language, and that I don't particularly
"want greater integrity properties" (despite desiring the side
effects :) ).
so you could say that I've had a little bit of a taste of what's to
come. One experience of mine you might be interested in is as a
consumer of Adobe's Flex framework. Quite often, I feel the need to
extend the various Flex classes (as you do). Unfortunately, many of
the classes have properties defined as "private" instead of
"protected", despite being clearly suitable candidates for consumers
to extend. This results in developers like myself being forced to
copy-paste entire classes just to override "high integrity"
Do you get the feeling that the majority of developers who aren't
language that doesn't fit their development profile? Do you think
to those who are used to a more traditional approach?
My gut feeling to those two questions are "yes" and "no", but
unfortunately that's all it is; a gut feeling.
Nathan de Vries
More information about the Es4-discuss