Re:Type hints – a mediocre programmer's reaction (2015)
by aidenn0 on Friday March 18, 2016 @12:23AM
(#11309888)
You have a seekable filelike interface that is a superset of the base filelike interface.
Re:Type hints – a mediocre programmer's reaction (2015)
by Retra on Thursday March 17, 2016 @09:35PM
(#11309209)
>I'm not sure any committee could agree as to what defines a filelike object (does it implement seek?)
You step back a layer of abstraction. Maybe it implements seek, maybe it doesn't. Either way it implements has_seek.
In addition you'd need an IRO (interface resolution order) if you truly intended to prove everything would work
To say nothing of accidentally implementing an interface and getting an error because if it
Doesn't sound like my kind of python...