[Python-ideas] Make os.pipe() return a namedtuple.

Chris Angelico rosuav at gmail.com
Tue Jun 30 09:03:23 CEST 2015

On Tue, Jun 30, 2015 at 5:02 PM, Jonathan Slenders <jonathan at slenders.be> wrote:
> If we use "read" and write as names. It means that often we end up writing
> code like this:
> os.write(our_pipe.write, data)
> os.read(our_pipe.read)
> Is that ok? I mean, it's not confusing that the os.read is a method, while
> pip.read is an attribute.

I'd much rather that than the converse. You always put read with read,
you always put write with write.


More information about the Python-ideas mailing list