News for hackers. Stuff that matters.
Re:PyCon 2015: Are we still changing the world? by msellout on Monday May 11, 2015 @12:22PM (#9525882)
You can ignore the type hints syntax. I plan to.

Python 2:

    map(func, iterable)   # returns a list
Python 3:

    map(func, iterable)         # returns an iterator
    list(map(func, iterable))   # returns a list
Re:PyCon 2015: Are we still changing the world? by jMyles on Monday May 11, 2015 @12:32PM (#9525950)
> You can ignore the type hints syntax. I plan to.

I feel like that will be quite an ear-plugging, eye-covering endeavor.

And that's really the point: it has the potential to create a community in which half the people are eyes-closed, ears-plugged.

On your second point: Yeah, I don't mind casting things to a list. But it does seem... I guess, dramatic.

Re:PyCon 2015: Are we still changing the world? by tedmiston on Monday May 11, 2015 @01:00PM (#9526156)
> And that's really the point: it has the potential to create a community in which half the people are eyes-closed, ears-plugged.

This is a big concern of mine as well, both before/after listening to Guido's keynote on Type Hinting at PyCon (https://www.youtube.com/watch?v=2wDvzy6Hgxg).

At first I thought type hinting would only really see adoption in performance-oriented sections of code, but I think we're all curious to see what best practices emerge in general, and in the open source side of things. Really the additional robustness it unlocks for IDEs like JetBrains is what got me really excited about type hints in Python.

Re:PyCon 2015: Are we still changing the world? by jMyles on Monday May 11, 2015 @01:06PM (#9526199)
> Really the additional robustness it unlocks for IDEs like JetBrains is what got me really excited about type hints in Python.

Agreed. But that's only useful if the syntax is non-awful.

Re:PyCon 2015: Are we still changing the world? by msellout on Tuesday May 12, 2015 @11:09PM (#9536509)
It's not technically a cast to a list. It's using the list constructor with the iterator as an argument.