Jonathan said:
A.M. Kuchling said:
The list of features for Python 3000 is described in PEP 3000,
appropriately enough:
http://www.python.org/peps/pep-3000.html
Most of the suggested changes remove redundancy, such as removing
now-unneeded built-in functions and language features.
I'm sure this has been brought up before, but a quick google search
didn't find anything on moving [has|get|set]attr into attributes of
object. Why wouldn't this be considered a Good Thing? Just because
Ruby people would like it?
You can take this step even further:
The builtin functions (that aren't doomed for py3k) can be classified in
those groups:
A. Constructors for built-in types
basestring, bool, complex, dict, file, float, int, list, long, object,
str, slice, tuple, type
These cannot be made attributes of some object.
B. Functions that can be attributed to some class or module
abs, divmod, round, pow -> math
ord -> str
In consequence: [uni]chr -> int
hex, oct -> int
super, *attr, isinstance, issubclass -> object
hash -> sys?
C. Functions that could be made attributes of lists/sequences
max, min, len, enumerate, sum
But that would require to implement them for all sequence types or
implement a common basetype 'seq'.
D. Other functions I cannot attribute to a class
eval
globals, locals, vars
iter
property
classmethod, staticmethod
cmp
[x]range
repr
__import__
Reinhold