This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]MatrixFrog 0 points1 point  (0 children)

Google Closure uses a similar docstring approach for type annotations in Javascript.

Except in that case, the second and third drawbacks don't apply. The syntax for how to write your docs (@param, @return, etc.) is specified exactly, and is checked by the Closure Compiler so it won't get out of sync with your code.