Am 05.11.2011 23:26, schrieb Antoine Pitrou:
Given it returns an eternal object, and it's almost always used
temporarily (for attribute lookup, string joining, etc.), it would seem
more practical for it to return a borrowed reference.
For purity reasons: all PyUnicode_From* functions return
I agree in principle, but one thing you get with setup.cfg which seems harder
to
achieve with MSI is the use of Python to do things at installation time. For
example, with setup.cfg hooks, you can use ctypes to make Windows API calls at
installation time to decide where to put things. While
I had announced this to import-sig already; now python-dev.
I have now written an implementation of PEP 382, and fixed some details
of the PEP in the process. The implementation is available at
http://hg.python.org/features/pep-382-2/
With this PEP, a Python package P can consist of either a
list.index() and list.tuple() don't currently accept None as slice
parameters, as reported in http://bugs.python.org/issue13340. For
example:
[1, 2, 3].index(2, None, None)
Traceback (most recent call last):
File stdin, line 1, in module
TypeError: slice indices must be integers or None or
On Sun, Nov 6, 2011 at 6:10 PM, Martin v. Löwis mar...@v.loewis.de wrote:
I had announced this to import-sig already; now python-dev.
I have now written an implementation of PEP 382, and fixed some details
of the PEP in the process. The implementation is available at
Write Oleg,
If there is a better way to implemant this? sure. But the idea is still good.
___
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
On Sun, Nov 6, 2011 at 7:29 AM, Nick Coghlan ncogh...@gmail.com wrote:
I think this was based on the assumption that *existing* namespace
package approaches would break under the new scheme. Since that is not
the case, I suspect those previous objections were overstated (and all
packaging
Le 05/11/2011 17:34, Éric Araujo a écrit :
Hi Victor,
PyDict_GetItem() and PyDict_SetItem() don't call __getitem__ and __setitem__
for dict subclasses. Is there a reason for that?
http://bugs.python.org/issue10977 “Currently, the concrete object C API
bypasses any methods defined on
Le 06/11/2011 08:08, Martin v. Löwis a écrit :
Am 05.11.2011 23:26, schrieb Antoine Pitrou:
Given it returns an eternal object, and it's almost always used
temporarily (for attribute lookup, string joining, etc.), it would seem
more practical for it to return a borrowed reference.
For purity
On Sun, 6 Nov 2011 09:49:27 +0200
Petri Lehtinen pe...@digip.org wrote:
list.index() and list.tuple() don't currently accept None as slice
parameters, as reported in http://bugs.python.org/issue13340. For
example:
[1, 2, 3].index(2, None, None)
Traceback (most recent call last):
File
On Mon, Nov 7, 2011 at 8:16 AM, Antoine Pitrou solip...@pitrou.net wrote:
Either that or fix the error message. I can't find much benefit in
accepting None, that said (nor in refusing it).
Its very convenient when working with slices to not have to special
case the end points. +1 on accepting
2011/11/6 brian.curtin python-check...@python.org:
-
- if (!PyArg_ParseTuple(args, OO:utime,
+ PyObject* arg = NULL;
You could set arg = Py_None here.
+
+ if (!PyArg_ParseTuple(args, O|O:utime,
PyUnicode_FSConverter, opath, arg))
return NULL;
On Sun, Nov 6, 2011 at 13:46, Benjamin Peterson benja...@python.org wrote:
2011/11/6 brian.curtin python-check...@python.org:
-
- if (!PyArg_ParseTuple(args, OO:utime,
+ PyObject* arg = NULL;
You could set arg = Py_None here.
+
+ if (!PyArg_ParseTuple(args, O|O:utime,
On Nov 6, 2011, at 12:49 AM, Petri Lehtinen wrote:
Currently, find(), rfind(), index(), rindex(), count(), startswith()
and endswith() of str, bytes and bytearray accept None. Should
list.index() and tuple.index() accept it, too?
The string methods accept None as a historical artifact
of
I think this was based on the assumption that *existing* namespace
package approaches would break under the new scheme. Since that is not
the case, I suspect those previous objections were overstated (and all
packaging related code manages to cope well enough with modules where
the file name
Am 06.11.2011 16:38, schrieb PJ Eby:
On Sun, Nov 6, 2011 at 7:29 AM, Nick Coghlan ncogh...@gmail.com
mailto:ncogh...@gmail.com wrote:
I think this was based on the assumption that *existing* namespace
package approaches would break under the new scheme. Since that is not
the
Am 06.11.2011 17:39, schrieb Antoine Pitrou:
Le 05/11/2011 17:34, Éric Araujo a écrit :
Hi Victor,
PyDict_GetItem() and PyDict_SetItem() don't call __getitem__ and
__setitem__
for dict subclasses. Is there a reason for that?
http://bugs.python.org/issue10977 “Currently, the concrete object
17 matches
Mail list logo