Why no number methods?

Magnus Lie Hetland mlh at idi.ntnu.no
Tue May 15 12:26:32 EDT 2001


From: "Paul Foley" <mycroft at actrix.gen.nz>
>
> On Mon, 14 May 2001 15:22:43 +0200, Magnus Lie Hetland wrote:
>
> > From: "Paul Foley" <mycroft at actrix.gen.nz>
> [That was in email, not a Usenet post, BTW]
> >> Have you been brainwashed into thinking that something's only OO if
> >> you can use some foo.bar() nonsense?
>
> > Whoa! Now _there's_ a loeaded question. I'll politely answer
> > "no", and leave it at that.
>
> Erm; I suspect you read that with rather more force than was intended.

Glad to hear it. Sorry, about that... :)

> > Really? Now that's interesting. I would have thought that neither
> > was "more" object-oriented than the other. As far as I know,
> > object-orientedness has little to do with syntax...
>
> No, it has nothing to do with syntax per se, and for the one-argument
> case it makes no difference, of course, but when you allow multiple
> arguments foo.bar(baz) or foo.bar(baz, quux) vs. bar(foo, baz) or
> bar(foo, baz, quux), etc., then the former syntax makes the first
> argument stand out in a way that harms "OO-ness".  See below.

I see your point.

> I abhor Scheme!  CL is my preferred language, yes, but I'm not
> specifically talking about CL.

Hm. CL is your preferred language and you abhor Scheme? Cool :)
To me they seem ... well ... pretty similar :)

> In SmallTalk it isn't broken -- but SmallTalk only has single
> inheritance, which makes a difference.  I don't know about Ruby.

Neither do I, I guess :)

[explanation snipped]

Thank you for a clarifying explanation. (Makes me curious about
how it's really done in Ruby... ;)

> [I read a good paper on this topic a while back which I would
> refer you to, but I can't find it now...I *think* it was by Luca
> Cardelli; you could try searching for his name on google, if you're
> interested]

I've got his bok "A Theory of Objects" -- never got through it all,
but find it very interesting. Maybe I *will* look for the paper.
(You don't, by any chance, remember the title, or some title words?)

Again -- sorry I misread your original post.

--

  Magnus Lie Hetland         http://www.hetland.org

 "Reality is that which, when you stop believing in
  it, doesn't go away."           -- Philip K. Dick






More information about the Python-list mailing list