"Mike Meyer" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
> Magnus Lycka <[EMAIL PROTECTED]> writes:

>> Terry Reedy wrote:
>>> However, everything is an instance of a class or type.

>> Except whitespace, comments, operators and statements!
>> (Did I miss anything?)

> [snip] Maybe the properly
> refined version of Terry's statement should be:
>
>        Everything you can manipulate is an instance of a class or a
>        type.

Yes and no.

First, the context of the statement was a previous claim that some things 
are class instances and some not.   So my point in that context was a) that 
adding 'or type' changes 'some' to 'every' and that new classes mostly 
eliminate the difference between class and type, making the addition 
eminently sensible.  So while I thought of a qualifier like that, I left it 
out as irrelevant and a distractions.

Second, any qualifier I can think of seems to have the danger of confusing 
as well as enlightening.  One might not realize, for instance, that 
functions are something you can manipulate and might therefore mistakenly 
think that the qualifier excludes functions.  I also thought of putting it 
as 'everything in Python's dataspace ...', but that has the same problem.

Perhaps 'every runtime entity...'. would work. That seems to excludes 
source code (and things within source code like comments and whitespace and 
operator symbols), unless the code or pieces thereof *are* turned into (or 
wrapped as) string instances.  Names might seem like an exception, but 
again, they are only accessible at runtime as string instances.  Or maybe a 
more direct statement 'except for source code, everything...' would be 
better.

So I have so far not settled on a 'best' context-free statement of the 
design principle.

Terry J. Reedy



-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to