[Python-ideas] Proposal: Use mypy syntax for function annotations
Rock Neurotiko
miguelglafuente at gmail.com
Sat Aug 23 01:50:49 CEST 2014
Yes, and the Scala version need a " = {}", I was talking just about how the
syntax of the types and annotations are, I omitted the ':' because it was
irrelevant.
2014-08-23 1:36 GMT+02:00 Terry Reedy <tjreedy at udel.edu>:
> On 8/22/2014 3:47 AM, Rock Neurotiko wrote:
>
> About the syntax, I love the mypy's syntax, and remember me a lot to
>> other languages like scala.
>>
>> def primes_to_n(n: Int) => List[Int]
>>
>> def primes_to_n(n: int) -> List[int]
>>
>
> The Python version need ':' at the end, after the return type.
> I don't think you are the first to omit it.
>
> --
> Terry Jan Reedy
>
>
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
>
--
Miguel García Lafuente - Rock Neurotiko
Do it, the devil is in the details.
The quieter you are, the more you are able to hear.
Happy Coding. Code with Passion, Decode with Patience.
If we make consistent effort, based on proper education, we can change the
world.
El contenido de este e-mail es privado, no se permite la revelacion del
contenido de este e-mail a gente ajena a él.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20140823/81c78063/attachment-0001.html>
More information about the Python-ideas
mailing list