4 ms·
This isn't so easy when you're trying to parse a hundreds-line function written by god knows who that has many early returns each returning an object with wildl
by wildrhythms 4y ago
This isn't so easy when you're trying to parse a hundreds-line function written by god knows who that has many early returns each returning an object with wildly different properties. Declaring the return type the method declaration is valuable.
- brundolf 4y agoIf you just need to read the return type, I don't see why in this case you'd be prevented from hovering the function to see it If you want to constrain the return type so that any errors about bad return-values from this function are localized to it, instead of having them show up further downstream, then that's what I meant by "other reasons to use explicit types"