[Pyrex] [Cython-dev] kw-only arguments?
Robert Bradshaw
robertwb at math.washington.edu
Thu Sep 27 23:29:24 CEST 2007
On Sep 25, 2007, at 12:08 AM, Stefan Behnel wrote:
> Robert Bradshaw wrote:
>> What is the plan for P3k vs. Python 2.x? Should there be a separate
>> branch? I imagine the ParseArgumentsAndKeywords function will
>> change to
>> reflect this in P3k, so much of this "manual labor" will be
>> redundant.
>
> There is the "py3k" branch in Python's SVN, but since the PEP
> doesn't say
> anything about changes to the C API, I don't expect anything to
> happen any
> time soon. I mean, you can easily do this in plain C code already
> by parsing
> the args accordingly. It's just not currently available in Pyrex/
> Cython, as
> you can't adapt the way it parses the arguments from Pyrex code.
I meant you'd be able to just pass it a string, like you do now for
the rest of the arguments.
> The patch isn't that long, and there isn't usually that much
> "manual labour"
> involved in the generated code. It's pretty optimised already.
>
> Regarding the general question about a 3k branch for Cython: I'd
> rather wait
> and see if we can't handle that with conditional compilation as we
> currently
> do with most newer features. I prefer keeping Cython a single tool
> for all
> target architectures and versions as long as we can. And it would
> be great to
> generate C code that compiles and works without changes for Python
> 2.3 through
> Python 3.0. :]
This is my hope too, no idea how realistic it is though.
- Robert
More information about the Pyrex
mailing list