Case sensitivity

Magnus Lie Hetland mlh at
Tue Feb 25 03:31:04 CET 2003

In article <v5lfj0h9m6172f at>, John Roth wrote:
> Other than that, I would be very, very happy if the compiler refused
> to compile anything with the same name capitalized in more than one
> way.
> I'd even be willing to extend the prohibition to names that only
> differed by the presence or absence of internal underscores.

Really? Why not go further -- to disallow names with a Levenshtein
distance of 2 or less, for example (i.e. only two editing operations
needed to change one into the other)?

I think all of this is going quite a bit too far (even with my
excellent edit distance suggestion omitted). I think, for example,
that the following is quite natural:

class Airplane:

class Hangar:
    def accept(self, airplane):

I might, of course, adopt some SmallTalkish idiom, writing anAirplane
instead of airplane, but I don't see how this improves the code at
all... Giving it a more meaningful name (such as incomingAirplane or
whatever) might be a good thing, but I'm not convinced that this is
called for in _every_ situation...

> John Roth

Magnus Lie Hetland               "Nothing shocks me. I'm a scientist."                                   -- Indiana Jones

More information about the Python-list mailing list