|
|
|
|
|
by iamforreal
2948 days ago
|
|
Honestly, I would just not use it wherever possible. It's a wart on the language, and there are plenty of semantically superior alternatives. I would rather wrap in function + use return over break, use a sentinel value, or raise an exception over using the else block. If there's anything I've learned, it's that just because a language has a feature, doesn't mean it should be used. |
|
You shouldn't use a feature just because a language has it, you should use it because it's a simple, well-defined primitive that's less complex than alternatives.