r/cpp • u/anonymous23874 • Apr 19 '20
Default function arguments are the devil
https://quuxplusone.github.io/blog/2020/04/18/default-function-arguments-are-the-devil/
90
Upvotes
r/cpp • u/anonymous23874 • Apr 19 '20
View all comments
Show parent comment
21
u/be-sc Apr 19 '20
It applies to all the language features including
goto. If you have a situation where using agotois the most concise, readable and safe solution, not using it just because “goto is bad” would be outstandingly silly. Such situations might be rare, but when you encounter one why would you want to write suboptimal code on purpose?