Re: [Python-Dev] Tweaking PEP 8 guidelines for use of leading underscores

2013-07-17 Thread Daniel Holth
https://pypi.python.org/pypi/apipkg provides a much more effective way to denote API than an _ On Wed, Jul 17, 2013 at 12:20 PM, R. David Murray wrote: > On Tue, 16 Jul 2013 17:46:34 -0400, Terry Reedy wrote: >> On 7/16/2013 9:39 AM, R. David Murray wrote: >> > On Tue, 16 Jul 2013 23:19:21 +1000

Re: [Python-Dev] Tweaking PEP 8 guidelines for use of leading underscores

2013-07-17 Thread R. David Murray
On Tue, 16 Jul 2013 17:46:34 -0400, Terry Reedy wrote: > On 7/16/2013 9:39 AM, R. David Murray wrote: > > On Tue, 16 Jul 2013 23:19:21 +1000, Steven D'Aprano > > wrote: > > >> For example, pkgutil includes classes with single-underscore methods, > >> which I take as private. It also has a func

Re: [Python-Dev] String terminology [was Re: Misc re.match() complaint]

2013-07-17 Thread Guido van Rossum
When precision is needed I say things like 'a str object' or 'a bytes object'. There is no shame in a bit of verbosity around such issues, especially in the reference docs (tutorials are a different issue). On Wed, Jul 17, 2013 at 4:50 AM, Steven D'Aprano wrote: > On 17/07/13 19:05, Terry Reedy w

Re: [Python-Dev] Misc re.match() complaint

2013-07-17 Thread MRAB
On 17/07/2013 05:15, Stephen J. Turnbull wrote: Terry Reedy writes: > On 7/15/2013 10:20 PM, Guido van Rossum wrote: > > >> Or is this something deeper, that a group *is* a new object in > >> principle? > > > > No, I just think of it as returning "a string" > > That is exactly wha

Re: [Python-Dev] Tweaking PEP 8 guidelines for use of leading underscores

2013-07-17 Thread Barry Warsaw
On Jul 17, 2013, at 09:35 AM, Brett Cannon wrote: >Or how about dropping the whole ``from ... import ...`` format entirely? ><0.5 wink; seriously, it's implementation is a pain and it has wonky >semantics> Yes, let's break *everything* :) -Barry signature.asc Description: PGP signature ___

Re: [Python-Dev] Tweaking PEP 8 guidelines for use of leading underscores

2013-07-17 Thread Brett Cannon
On Tue, Jul 16, 2013 at 9:07 PM, Barry Warsaw wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > On Jul 16, 2013, at 07:34 PM, Tres Seaver wrote: > > >On 07/16/2013 07:09 AM, Nick Coghlan wrote: > > > >> I did find it interesting that we *don't* explicitly advise against > >> the use

Re: [Python-Dev] Misc re.match() complaint

2013-07-17 Thread Serhiy Storchaka
16.07.13 20:21, Guido van Rossum написав(ла): The situation is most egregious if the target string is a bytearray, where there is currently no way to get the result as an immutable bytes object without an extra copy. (There's no API that lets you create a bytes object directly from a slice of a b

[Python-Dev] String terminology [was Re: Misc re.match() complaint]

2013-07-17 Thread Steven D'Aprano
On 17/07/13 19:05, Terry Reedy wrote: Saying that input arguments can be "Unicode strings as well as 8-bit strings' (the wording is from 2.x, carried over to 3.x) does not necessary exclude other inputs. "8-bit strings" seems somewhat ambiguous to me. In UTF-8, many Unicode strings are 8-bi

Re: [Python-Dev] PEP 446: Add new parameters to configure the inherance of files and for non-blocking sockets

2013-07-17 Thread Victor Stinner
2013/7/13 Cameron Simpson : > This sentence: > > The flag is cleared in the child process before executing the > program, the change does not change the flag in the parent process. > > needs a semicolon, not a comma. Fixed. Victor ___ Python-Dev mai

Re: [Python-Dev] PEP 446: Add new parameters to configure the inherance of files and for non-blocking sockets

2013-07-17 Thread Victor Stinner
2013/7/7 Cameron Simpson : > On 06Jul2013 14:43, Victor Stinner wrote: > | 2013/7/6 Cameron Simpson : > | > Yes. Please forget I mentioned fork(); it is only relevant if you > | > were offering some facility to undo the addition of cloexec to a > | > Popen passed file descriptor. Which you are not

Re: [Python-Dev] PEP 446: Add new parameters to configure the inherance of files and for non-blocking sockets

2013-07-17 Thread Victor Stinner
2013/7/7 Charles-François Natali : > Well, it complicates the signature and implementation. > If we go the same way, why stop there and not expose O_DSYNC, O_SYNC, > O_DIRECT... I added this counter-argument to the PEP. > If you want precise control over the open() sementics, os.open() is > the w

Re: [Python-Dev] Misc re.match() complaint

2013-07-17 Thread Stephen J. Turnbull
Terry Reedy writes: > > "stringish" > > This word is an adjective, not a noun. Ah, a strict grammarian. That trumps any cards I could possibly play. ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/pytho

Re: [Python-Dev] Misc re.match() complaint

2013-07-17 Thread Terry Reedy
On 7/17/2013 12:15 AM, Stephen J. Turnbull wrote: Terry Reedy writes: > On 7/15/2013 10:20 PM, Guido van Rossum wrote: > > >> Or is this something deeper, that a group *is* a new object in > >> principle? > > > > No, I just think of it as returning "a string" > > That is exactly w