News for hackers. Stuff that matters.
Re:PEP 3107 – Function Annotations in Python 3 by JulianWasTaken on Monday May 12, 2014 @07:14AM (#7732047)
A feature without a use case still unfortunately. There are some in the PEP, but given how little code is Py3-only, no one has written anything notable that I've seen that makes use of these.
Re:PEP 3107 – Function Annotations in Python 3 by kunstmord on Monday May 12, 2014 @08:11AM (#7732252)
As mentioned, PyCharm supports this – I found it very useful when writing large amounts of code, saves time when trying to remember what type which variable should be (sometimes it's not evident from the input variable names).

And this looks a tad easier to find and understand than the standard docstring variable types description.

Re:PEP 3107 – Function Annotations in Python 3 by michaelmior on Monday May 12, 2014 @08:07AM (#7732233)
This would be great to have some subset of Cython[1] become valid Python code so it could be executed as normal Python code. The syntax is different, but function annotations could provide the necessary info.

[1] http://cython.org/

Re:PEP 3107 – Function Annotations in Python 3 by d0mine on Monday May 12, 2014 @10:06PM (#7736306)
There is a pure python mode http://docs.cython.org/src/tutorial/pure.html that works even in Python 2.
Re:PEP 3107 – Function Annotations in Python 3 by andreasvc on Monday May 12, 2014 @09:49AM (#7732618)
It's already available as a beta feature in Cython.
Re:PEP 3107 – Function Annotations in Python 3 by guipsp on Monday May 12, 2014 @12:36PM (#7733742)
Link?
Re:PEP 3107 – Function Annotations in Python 3 by andreasvc on Monday May 12, 2014 @01:36PM (#7734170)
Re:PEP 3107 – Function Annotations in Python 3 by shoo on Monday May 12, 2014 @07:25AM (#7732086)
i agree with your sentiment but not how you have literally worded it - there are plenty of serious use cases listed in the PEP, eg typechecking by itself is rather useful in other languages, but it is perhaps hard to imagine how useful this feature will be if no existing libraries support it, and there is no common standard defining what any of the annotations could mean.

on the other hand, this could be quite useful for large (proprietary?) python codebases where common standards can be defined and rolled out and enforced.

Re:PEP 3107 – Function Annotations in Python 3 by philliproso on Monday May 12, 2014 @07:35AM (#7732119)
It is nicely integrated with type checking in the pycharm IDE. This feature is one of the reasons I would personally like to write pure py3 code.
Re:PEP 3107 – Function Annotations in Python 3 by lukasm on Monday May 12, 2014 @07:35AM (#7732117)
One use case: improved JITer performance.