[Python-Dev] collections.abc for data and non-data descriptors
Ivan Levkivskyi
levkivskyi at gmail.com
Wed Jan 18 05:25:48 EST 2017
A random thought: typing has ABCs for protocols, even more than
collections.abc has (e.g. typing.SupportsInt). Some support for descriptors
has been added to mypy recently.
Maybe it makes sense to add support for descriptor protocol in typing?
--
Ivan
On 18 January 2017 at 05:44, Raymond Hettinger <raymond.hettinger at gmail.com>
wrote:
>
> > On Jan 17, 2017, at 11:41 AM, Roberto Martínez <
> robertomartinezp at gmail.com> wrote:
> >
> > Oh, I understand. Maybe is not worth the effort anyway.
>
> FWIW, I'm also in the camp of thinking it is not worth the effort. Until
> there is a demonstrated need (something than can't be met by checking for
> __set__), the default position should be to stick with a core usable set of
> ABCs that are know to have real value. Each new ABC has a non-trivial
> maintenance burden and requires extra effort on the part of users to learn
> and remember.
>
>
> Raymond
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: https://mail.python.org/mailman/options/python-dev/
> levkivskyi%40gmail.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20170118/00236f4b/attachment.html>
More information about the Python-Dev
mailing list