logoalt Hacker News

pkkm • today at 1:39 PM • 0 replies • view on HN

PHP does have return type annotations. The reason the PHPDoc comments are needed here is that it lacks generics. Unfortunately, adding generics has proven problematic, but I still hope that we'll see them in the next few years.