3 ms·
> "Functions always have a single entry point; they should have a single exit point." Kind of moot as soon as you are using a language with exceptions, where b
by kilburn 5y ago
> "Functions always have a single entry point; they should have a single exit point."
Kind of moot as soon as you are using a language with exceptions, where by definition every function can have surprise exit points at every point where they call another function.
Furthermore, the whole "goto is evil" ordeal has been debunked by the top professionals in our field [1] and discussed many times here on HN [2,3,4,5].
[1] https://koblents.com/Ches/Links/Month-Mar-2013/20-Using-Goto-in-Linux-Kernel-Code/ https://koblents.com/Ches/Links/Month-Mar-2013/20-Using-Goto...
[2] https://news.ycombinator.com/item?id=18484221 https://news.ycombinator.com/item?id=18484221
[3] https://news.ycombinator.com/item?id=19959592 https://news.ycombinator.com/item?id=19959592
[4] https://news.ycombinator.com/item?id=14540088 https://news.ycombinator.com/item?id=14540088
[5] https://news.ycombinator.com/item?id=8760518 https://news.ycombinator.com/item?id=8760518