Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Brett Cannon
On 2/10/07, Steve Holden [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: On Sun, Feb 11, 2007 at 03:35:29AM +0200, Yotam Rubin wrote: Why don't you use Stackless? It's very simple, stable, and solves quite completely the problems in writing concurrect code. That's a great point -- I'm

Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Martin v. Löwis
Brett Cannon schrieb: Of course Stackless isn't quite fully integrated with 2.5 (yet). When did someone last suggest that Stackless become part of the core CPython implementation, and why didn't that ever happen? Don't remember the when. The why has always been that Christian's hacks

[Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread skip
Someone checked in Parser/Python.asdl. After rebuilding Subversion tells me that Python/Python-ast.c has been modified. I assume the two are related. Did whoever checked in the former need to check in the latter (and maybe add a note to Misc/NEWS)? Skip

Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Richard Tew
On 2/11/07, Martin v. Löwis [EMAIL PROTECTED] wrote: Brett Cannon schrieb: Of course Stackless isn't quite fully integrated with 2.5 (yet). When did someone last suggest that Stackless become part of the core CPython implementation, and why didn't that ever happen? Don't remember

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Brett Cannon
On 2/11/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Someone checked in Parser/Python.asdl. After rebuilding Subversion tells me that Python/Python-ast.c has been modified. I assume the two are related. Did whoever checked in the former need to check in the latter Yeah, sorry about that.

Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Martin v. Löwis
Richard Tew schrieb: If these generator coroutine microthreads went ahead and part of it was improving the support for asynchronous calls in the runtime and standard library, this would also be something which also benefited Stackless Python. Even if they didn't go ahead I would be

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Martin v. Löwis
Brett Cannon schrieb: On 2/11/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Someone checked in Parser/Python.asdl. After rebuilding Subversion tells me that Python/Python-ast.c has been modified. I assume the two are related. Did whoever checked in the former need to check in the latter

Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Armin Rigo
Hi Martin, On Sun, Feb 11, 2007 at 07:09:29PM +0100, Martin v. L?wis wrote: hacks into the core were complicated and he didn't even think integration was worth it. With emphasis on the latter. Christian never proposed (to my knowledge) that Stackless should be integrated. Of course, he

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Guido van Rossum
On 2/11/07, Martin v. Löwis [EMAIL PROTECTED] wrote: Actually, the regenerating should happen immediately after commit, as this bumps the revision number of the asdl file. This means you have to make two commits per AST grammar change: one to change the grammar, and the other to update the

[Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Ben North
Hi, A few days ago I posted to python-ideas with a suggestion for some new Python syntax, which would allow easier access to object attributes where the attribute name is known only at run-time. For example: setattr(self, method_name, getattr(self.metadata, method_name)) from

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Delaney, Timothy (Tim)
Ben North wrote: c.5 uses which would have to stay as getattr because they are calls of a variable named getattr whose default value is the builtin getattr; Have you checked if these are intended to bring the getattr name into local scope for fast lookup,

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Anthony Baxter
On Monday 12 February 2007 13:57, Brett Cannon wrote: On 2/11/07, Guido van Rossum [EMAIL PROTECTED] wrote: On 2/11/07, Martin v. Löwis [EMAIL PROTECTED] wrote: Actually, the regenerating should happen immediately after commit, as this bumps the revision number of the asdl file. This

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Brett Cannon
On 2/11/07, Ben North [EMAIL PROTECTED] wrote: [SNIP] * The draft currently allows a two-argument form, to supply a default value if the object has no attribute of that name. This mimics the behaviour of the three-argument form of getattr, but looks a bit wrong: s = obj.(attr_name,

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Anthony Baxter
I have to say that I'm not that impressed by either the 1-arg or 2-arg versions. Someone coming across this syntax for the first time will not have any hints as to what it means - and worse, it looks like a syntax error to me. -1 from me. ___

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Collin Winter
I like the general idea, but the syntax looks like dirt on my monitor. The period is too easy to lose visually and without it, there's nothing to distinguish this from a function call. Also, like Anthony Baxter said, someone coming across this for the first time will think it's a syntax error,

Re: [Python-Dev] Trial balloon: microthreads library in stdlib

2007-02-11 Thread Martin v. Löwis
Armin Rigo schrieb: The history as I remember it is that Christian tried hard to integrate the first versions of Stackless with CPython, but was turned town by python-dev. Are there public records of that? As I remember it, Christian never actually submitted a patch for inclusion (at least not

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Neil Toronto
Anthony Baxter wrote: I have to say that I'm not that impressed by either the 1-arg or 2-arg versions. Someone coming across this syntax for the first time will not have any hints as to what it means - and worse, it looks like a syntax error to me. -1 from me. I'm not sure the looks

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Martin v. Löwis
Guido van Rossum schrieb: Is this documented somewhere? It wouldn't hurt if there was a pointer to that documentation right next to the line in Python-ast.c that gets modified by the regeneration. (I've been wondering about this a few times myself.) Done! Martin

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Martin v. Löwis
Brett Cannon schrieb: /* File automatically generated by %s. This module must be committed separately from each AST grammar change; the __version__ number is set to the revision number of the commit containing the grammar change. */ It doesn't completely show up in svn diff (when

Re: [Python-Dev] Does Python/Python-ast.c need to be checked in?

2007-02-11 Thread Martin v. Löwis
Anthony Baxter schrieb: This module must be committed separately from each AST grammar change; the __version__ number is set to the revision number of the commit containing the grammar change. */ Note that the welease.py script that builds the releases does a touch on the relevant

Re: [Python-Dev] New syntax for 'dynamic' attribute access

2007-02-11 Thread Georg Brandl
Collin Winter schrieb: I like the general idea, but the syntax looks like dirt on my monitor. The period is too easy to lose visually and without it, there's nothing to distinguish this from a function call. Also, like Anthony Baxter said, someone coming across this for the first time will