[Python-Dev] Type hints -- a mediocre programmer's reaction

Wolfgang Langner tds333+pydev at gmail.com
Thu Apr 23 14:48:58 CEST 2015


Hello,

On Thu, Apr 23, 2015 at 11:59 AM, Paul Sokolovsky <pmiscml at gmail.com> wrote:

> Hello,
>
> On Thu, 23 Apr 2015 10:43:52 +0200
> Wolfgang Langner <tds333+pydev at gmail.com> wrote:
>
> []
>
> > Also ask why no one used type specifier, they are possible since
> > Python 3.0 ?
> > Because it is the wrong way for Python.
>
> That's an example of how perceptions differ. In my list, everyone(*)
> uses them - MyPy, MicroPython, etc. Even more should use them (any JIT
> module, which are many), but sit in the bushes, waiting for a kick, like
> PEP484 provides.
>
>
> (*) Everyone of those who needs them. Otherwise, let's throw out
> metaclasses - noone uses them.
>
>
They are there to be used and won't go away.
But for most Libraries out there no one used it.

JIT (Numba), Cython and other compilers/tools doing optimization have their
own syntax and needs.
They need even more information like i32, i64, different floats and so on.
MyPy is really new and in development. And the docstring type spec way is
still possible.
MicroPython uses one annotation for their inline assembler stuff not type
hints.
For the library there are no type hints for function definitions.


Remark: I use Metaclasses, seldom but if needed very useful. :-)


-- 
bye by Wolfgang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20150423/6454d62d/attachment.html>


More information about the Python-Dev mailing list