Re:Python Type Hints
by ATsch on Saturday December 28, 2019 @08:04PM
(#21903074)
Well, before, I had docstrings that describe the interface and what types it would accept. Now I do the same, more compactly and easier, using type hints. And since it's machine readable, linters can how help you to identify some simple problems. I think it's a win all around. I think the right way to look at type annotations is as part of the documentation, not as part of the code.
[ Parent
| on HN ]
There are no comments on this comment yet.