Re: [Python-Dev] Caching float(0.0)

2006-10-02 Thread Tim Hochberg
[EMAIL PROTECTED] wrote:\/ Steve By these statistics I think the answer to the original question Steve is clearly no in the general case. As someone else (Guido?) pointed out, the literal case isn't all that interesting. I modified floatobject.c to track a few interesting floating

Re: [Python-Dev] Explicit Lexical Scoping (pre-PEP?)

2006-07-06 Thread Tim Hochberg
Ka-Ping Yee wrote: On Wed, 5 Jul 2006, Guido van Rossum wrote: On 7/5/06, Phillip J. Eby [EMAIL PROTECTED] wrote: Using the classic nonsense example: def counter(num): def inc(): .num += 1 return .num return inc Would this also use ..num

Re: [Python-Dev] Pre-PEP: Allow Empty Subscript List Without Parentheses

2006-06-09 Thread Tim Hochberg
Guido van Rossum wrote: On 6/9/06, Nicko van Someren [EMAIL PROTECTED] wrote: [...] The language doesn't have zero-dimensional arrays, although it doesn't prevent users from defining them. but why would one want to index a zero-dimensional array, since it has no dimensions? It should be

Re: [Python-Dev] Pre-PEP: Allow Empty Subscript List Without Parentheses

2006-06-09 Thread Tim Hochberg
Alex Martelli wrote: On Jun 9, 2006, at 4:55 PM, Greg Ewing wrote: ... Think about how you get from an N dimensional array to an N-1 dimensional array: you index it, e.g. A2 = [[1, 2], [3, 4]] # a 2D array A1 = A2[1] # a 1D array A0 = A1[1] # a 0D array??? print A0 What do you

Re: [Python-Dev] INPLACE_ADD and INPLACE_MULTIPLY oddities in ceval.c

2006-03-29 Thread Tim Hochberg
... Regards, Tim Hochberg ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com