[pypy-dev] Objects and types in the stdobjspace

holger krekel hpk at trillke.net
Sat Jun 14 19:32:51 MEST 2003


[Armin Rigo Thu, Jun 12, 2003 at 01:18:37PM +0200]
> Hello Holger,
> 
> On Tue, Jun 10, 2003 at 05:36:19PM +0200, holger krekel wrote:
> > Please find attached a modified "stringobject.py" where i 
> > implemented this convention. I found that the naming scheme
> > was confused sometimes and the new "enforcement" makes this
> > very regular and readable (IMHO, of course).
> 
> It seems pretty reasonable, to say the least. What do other people think about 
> this point ?
> 
> If accepted, the introspection-registering loop at the end of the file should
> probably be moved in a common location and called from the end of each
> xxxobject.py file.

i just checked in Revision 809 which does this for all the xxxobject.py
files and a few xxxtype.py files. For some details see 

    http://codespeak.net/pipermail/pypy-svn/2003-June/000347.html

The only exception is intobject.py because test/test_intobject.py
directly uses the names in intobject.py instead of going through
the StdObjSpace or Type object.  I didn't fully understand the
OverflowError/restricted_int business so i left the intobject
for the time beeing. Any comment appreciated. 

After changing the registration mechanism i think the xxxobject.py
files are now in a more consistent and easier-to-read state. 
Hopefully i didn't break anything. 

greetings,

    holger


More information about the pypy-dev mailing list