Hacker News new | ask | show | jobs
by Findecanor 1406 days ago
My personal opinion is that a programming language should instead of 'goto', have explicit constructs for those things that 'goto' is most often used to emulate:

• Breaking out of nested loops

• Clause after loop that has run to its end-condition without a break, return or throw. Python allows an 'else'-clause after a loop, but IMHO "default" would be a better keyword.

• Error handling (C++ has exception handling already, but there are alternatives)

1 comments

This is interesting, are there languages in use today with these constructs?