Kevin Tew wrote: >> > Point well taken, I've been leaning back between, rewrite and evolving > your work. > I have a current change set that is passing most of your original tests > that are in t/dynclasses/py*.t > It is more of an evolution than a rewrite, which I favor. > Some test fail due to remaining uunimplemented features in > leo-cxt5(default args), or my lack of understanding. > But a lot of the tests pass.
Take a look at the following: Python 2.4.1 (#2, Mar 30 2005, 21:51:10) [GCC 3.3.5 (Debian 1:3.3.5-8ubuntu2)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> def f(a,b=1,c=2): ... pass ... >>> f.func_defaults (1, 2) In December, this was fully implemented and tested. In pirate.py, search for self.append("setprop %s, 'func_defaults', %s" % (ref, defaults)) and search for func_defaults in pyfunc.pmc, pyboundcall.pmc, and pybuiltin.pmc. Finally, take a look at the third test in parrot/languages/python/t/basic/func.t - Sam Ruby