[pypy-svn] rev 714 - pypy/trunk/src/pypy/objspace/std
arigo at codespeak.net
arigo at codespeak.net
Thu May 29 19:23:15 CEST 2003
Author: arigo
Date: Thu May 29 19:23:15 2003
New Revision: 714
Modified:
pypy/trunk/src/pypy/objspace/std/objspace.py
Log:
breaking things up purposefully, letting Christian fix them
Modified: pypy/trunk/src/pypy/objspace/std/objspace.py
==============================================================================
--- pypy/trunk/src/pypy/objspace/std/objspace.py (original)
+++ pypy/trunk/src/pypy/objspace/std/objspace.py Thu May 29 19:23:15 2003
@@ -23,6 +23,8 @@
def __init__(self):
self.dispatch_table = {}
def register(self, function, *types):
+ assert len(types) == function.func_code.co_argcount - 1, \
+ "wrong number of W_Xxx arguments to .register()"
if types in self.dispatch_table:
raise error, "we already got an implementation for %r" % types
self.dispatch_table[types] = function
More information about the Pypy-commit
mailing list