3 ms·
IMO jumping to labels is obviated in modern languages by low cost inline lambdas. Instead of complex loop breaking logic, stick the body in a lambda and use ret
by mgraczyk 5y ago
IMO jumping to labels is obviated in modern languages by low cost inline lambdas. Instead of complex loop breaking logic, stick the body in a lambda and use return. It's easier for me to follow and gives you more control over what's in scope. It also makes refactoring easier later on.
- brandmeyer 5y agoI am reminded of "Lambda: The Ultimate GOTO" https://dspace.mit.edu/handle/1721.1/5753 https://dspace.mit.edu/handle/1721.1/5753