Why we will use obj$func() often

Donn Cave donn at u.washington.edu
Wed Apr 28 14:02:49 EDT 2004


In article <5vJjc.13116$Qy.1954 at fed1read04>,
 "Mark Hahn" <mark at prothon.org> wrote:
...
> I guess the whole problem is my insistence on simple scope indentification
> by looking at the variable.  It causes the var to need to be tagged.

Well, in a sense this is a simplistic avoidance of scope.  Scope
is how unqualified identifiers are resolved.  You hope that actual
usage is simple enough that a relative qualifier will prop up the
weaknesses of Python's half-lexical, half-dynamic system;  Greg
points out that it doesn't handle more complex usage like nested
functions (and Simon's list comprehension / loop).  You can dismiss
those as uncommon problems, but then this whole feature addresses
a problem that bothers only those who choose to be afflicted.

> I feel strongly that the Python mixture of declaration (global), default
> (where assigned) and broken (closures) is broken overall and has to be fixed
> in Prothon.  I take this as a given.  So I see these possible solutions:
> 
> 1) My Ruby-like symbols, which I think are readable and fast-compilable.
> 
> 2) Word-like symbols, which are large, less readable (too me) and
> cluttering.
> 
> 3) Declarations, which cause the compiler and user to look around and are
> not Pythonic.
> 
> Am I missing any other solutions?

I've already talked about making scope purely lexical, only explicit
dynamic name space binding.
http://groups.google.com/groups?selm=1082827791.810981%40yasure&oe=UTF-8&
output=gplain

As I said there, declaration isn't an interesting part of that,
but the idea that declarations are "not Pythonic" strikes me as
particularly absurd (not to mention just seeing you, of all people,
offer this criticism.)  What is "class"?  What is "def"?

   Donn Cave, donn at u.washington.edu



More information about the Python-list mailing list