On Sun, Sep 04, 2016 at 12:31:26PM +0100, Mark Shannon wrote: > In other words PEP 484 specifically states that annotations are to help > with type inference. As defined in PEP 526, I think that type > annotations become a hindrance to type inference.
I'm pretty sure that they don't. Have you used any languages with type inference? Any type-checkers? If so, can you give some actual concrete examples of how annotating a variable hinders type inference? It sounds like you are spreading FUD at the moment. The whole point of type annotations is that you use them to deliberately over-ride what the checker would infer (if it infers the wrong thing, or cannot infer anything). I cannot see how you conclude from this that type annotations will be a hindrance to type inference. If you don't want to declare the type of a variable, simply DON'T declare the type, and let the checker infer whatever it can (which may be nothing, or may be the wrong type). -- Steve _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com