[Python-3000] Keyword Only Argument

2006-08-20 Thread Jiwon Seo
For the implementation of Implement PEP [PEP]3102 - Keyword Only Argument, it would be nice to have a (abstract) data structure representing the signature of a function. Currently, the code object only has # of arguments, # of default values, so if we want to allow something like, def foo(a,b=10,

[Python-3000] PEP3102 Keyword-Only Arguments

2006-08-11 Thread Jiwon Seo
When we have keyword-only arguments, do we allow 'keyword dictionary' argument? If that's the case, where would we want to place keyword-only arguments? Are we going to allow any of followings? 1. def foo(a, b, *, key1=None, key2=None, **map) 2. def foo(a, b, *, **map, key1=None, key2=None) 3.