Re: Class Variable Access and Assignment



Antoon Pardon wrote:
Op 2005-11-05, Steven D'Aprano schreef <steve@xxxxxxxxxxxxxxxxxxxxxx>:

On Fri, 04 Nov 2005 12:10:11 +0000, Antoon Pardon wrote:


There are good usage cases for the current inheritance behaviour. I asked
before what usage case or cases you have for your desired behaviour, and
you haven't answered. Perhaps you missed the question? Perhaps you haven't
had a chance to reply yet? Or perhaps you have no usage case for the
behaviour you want.

There are good use cases for a lot of things python doesn't provide. There are good use cases for writable closures, but python doesn't provide it, shrug, I can live with that. Use cases is a red herring here.

Is that a round-about way of saying that you really have no idea of whether, how or when your proposed behaviour would be useful?


I am not proposing specific behaviour. Because if I do, you will
just try to argue how much worst my proposed behaviour is.

Whether or not I can come up with a better proposal is irrelevant
to how sane the current behaviour is.

If you can't provide a superior alternative then you have little right to be questioning the present behavior. Honestly, you are like a child with a whistle who keeps blowing the whistle to the annoyance of all around it simply because it likes being able to make the noise, and causing the annoyance.

Personally, I think that when you are proposing a major change to a
language that would break the way inheritance works, there should be more
benefits to the new way than the old way.


How many times do I have to repeat myself. I'm not proposing a change
to the language.


So you have a clear impression that Python's current behavior is unsatisfactory enough to be called "unsane" which, when challenged, you insist simply means not at the extreme end of some imaginary sanity scale you have constructed for the purpose if bending English to your will. And you refuse to propose anything further towards the sane end of the scale because people will try to argue that your proposal would be worse than the existing behavior. Good grief, I though I was dealing with an adult here, but I must be mistaken.

Some things are a matter of taste: should CPython prefer <> or != for not
equal? Some things are a matter of objective fact: should CPython use a
byte-code compiler and virtual machine, or a 1970s style interpreter that
interprets the source code directly?

The behaviour you are calling "insane" is partly a matter of taste, but it
is mostly a matter of objective fact. I believe that the standard
model for inheritance that you call insane is rational because it is
useful in far more potential and actual pieces of code than the behaviour
you prefer -- and the designers of (almost?) all OO languages seem to
agree with me.

I didn't call the model for inheritance insane.

Well you are repeatedly call one aspect of the Python inheritance model insane. You appear to feel that repetition of an argument will make it more true, which is sadly not the case.

Antoon, I've been pedanted at by experts, and you ain't one. The behaviour
which you repeatedly described as not sane implements the model for
inheritance. The fact that you never explicitly said "the standard OO
model of inheritance" cuts no ice with me, not when you've written
multiple posts saying that the behaviour of that standard inheritance
model is not sane.


I haven't written that once. You may think that you can imply it from
what I wrote, but then that is your inferance and not my words.

Nonsense.

The standard behaviour makes it easy for code to do the right thing in
more cases, without the developer taking any special steps, and in the
few cases where it doesn't do the right thing (e.g. when the behaviour
you want is for all instances to share state) it is easy to work
around. By contrast, the behaviour you want seems to be of very limited
usefulness, and it makes it difficult to do the expected thing in
almost all cases, and work-arounds are complex and easy to get wrong.

Please don't make this about what I *want*. I don't want anything. I just noted that one and the same reference can be processed multiple times by the python machinery, resulting in that same reference referencing differnt variables at the same time and stated that that was unsane behaviour.

But you clearly don't perceive this as being related to Python's inheritance mechanism, presumably because you aren't prepared to accept that an instance inherits names from its class just like a class inherits names from its superclass.

"Unsane" now?

Heaven forbid that I should criticise people for inventing new words, but
how precisely is unsane different from insane? In standard English,
something which is not sane is insane.


Well maybe English works differently from dutch, but I thought there
were a whole lot of gradation between sane and insane. And not being
sane IMO just means not being at one end of the extreme while being
insane meant to be at the other end of the extreme.

So when something doesn't make complete sense, instead of it making
no sense at all, I would think that wording it as unsane instead of
insane resembles best what I intended to mean.

Ah, so Python isn't the only language you find insufficiently expressive. I normally give some leeway to those whose first language isn't English, but this particular bloody-mindedness has gone on long enough. I'd call your behavior imhelpful here.

So, are we talking about 0.1% insane, 10% insane or 90% insane. For someone who is so pedantic you are being insanely vague here. You can hardly blame people for concluding you just like the sound of your own voice (metaphorically speaking).

If you're just trolling, you've done a great job of it because you fooled
me well and good. But if you are serious in your criticism about the
behaviour, then stop mucking about and tell us what the behaviour should
be. Otherwise your criticism isn't going to have any practical effect on
the language at all.


I wasn't trolling. I just threw in an off hand remark. That you got so
heated up about that remark is not my responsibility. I'm not trolling
because I'm willing to defend my remark and I don't intend to get
people to get heated up about it. I just don't hold back because
people may get heated up about it.

The defense of your original remark implies very strongly that it wasn't offhand, and that you are indeed trolling. Hence the reduction in the frequency of my replies. You make it more and more difficult to take you seriously. Particularly since you have now resorted to a defense which involves refusing to define a non-existent word in any but the vaguest terms - you are trying to specify a position on the imaginary continuum of sanity, but you don't say how close to which end you are trying to specify. This puts you somewhere between "barmy" and "crackpot" on my own personal scale.

If you are serious about wanting the behaviour changed, and not just
whining, then somebody has to come up with an alternative behaviour that
is better.


If I would be whining I would want the behaviour changed. I would just
keep complaining about it until someone else would have changed it.

Instead you just keep complaining about it, full stop. Since we are all now fully aware of your opinions, couldn't you just shut up, or do we have to send you to your room without any supper? Whine, whine, whine.

Sure I would prefer it changed, but it is not that I *want* it to
change. I'll happily continue with python if it doesn't change.

That's sort of a pity. At this stage I'd recommend Ruby just to be rid of the incessant twaddle you come up with to defend your throwaway ideas.

Maybe when someone mentions something negative about python,
you shouldn't translate that into someone demanding a change
in python.


If not you, then who? Most of the folks who have commented on
this thread seem to like the existing behaviour.


Well fine, in that case it won't even change if I do come up with
an alternative proposal. So why should I bother?

Absolutely no reason at all. It's already transparently obvious that you don't have a better alternative and you continue to troll simply because it validates your particular (and increasingly peculiar) needs.

Every time I reply to you my spell checker looks at your name and shows me a dialog with an "ignore all" button on it. I have this increasing suspicion that it's trying to tell me something.

regards
 Steve
--
Steve Holden       +44 150 684 7255  +1 800 494 3119
Holden Web LLC                     www.holdenweb.com
PyCon TX 2006                  www.python.org/pycon/

.



Relevant Pages

  • Re: Random thoughts: Low power, High performance
    ... can consider it insane and refuse to port your software to it. ... if they go unusually mad, ... Hardware that pushes too far beyond "our" definition of "sane" and "usual" does have a history of getting neglected. ... Since 1999 on Intel x86. ...
    (comp.arch)
  • Re: The Golden Ear
    ... sane, or vice-versa. ... They think everybody else is insane. ... Can't prove that by your behavior, SHITR. ... That could be part of your insanity, ...
    (rec.audio.opinion)
  • Re: Another knight/knave hat puzzle
    ... A sane creature's beliefs are all true. ... An insane creature's beliefs are all false. ... Since sane humans and insane vampires both make true ... that his hat was black perfectly easily, ...
    (rec.puzzles)
  • Re: YASID: Re: Sanity in SF
    ... Character who's sane by our standards, ... and those who weren't sane become ... Some people adapted and became insane, while the sane people had real ... He just went with the chaotic flow. ...
    (rec.arts.sf.written)
  • Re: talk.origins darwinists lie about the holocaust
    ... It's insane, proposing an infinity of universes ... >decisions, acknowledge the weakness, stop behaving like nerds. ...
    (talk.origins)