News for hackers. Stuff that matters.
Re:Type hinting for Python by kmod on Tuesday January 06, 2015 @11:07PM (#8848841)
At least for Python, there are a different set of goals for programmer-productivity type hints (such as these) and for static-compilation type hints (such as you would need to provide optimizations).

One particular point is Python subclasses: it makes a lot of sense to say that a Python subclass is a subtype of the parent class, but in reality there are no guarantees about any relationship. This means that a compiler/VM would most likely have a hard time making use of type annotations since it would have to have to support the user passing arbitrary subclasses with completely different behavior.

There are no comments on this comment yet.