3 ms·
Recently I've had an argument with somebody bragging about they managed to bypass goto with writing following mess: do { r = allocate_resource();
by ernst_klim 4y ago
Recently I've had an argument with somebody bragging about they managed to bypass goto with writing following mess:
do {
r = allocate_resource();
if (!r)
break;
} while (false);
When I've said that this is just a messy unreadable version of goto, I was told that goto is harmful and this is a structured programming, which is superior. GOTOphobia is real.
- MrYellowP 4y agoIt's not GOTOphobia. It's people blindly doing what others are telling them to do (or not to do) without the ability to critically think about what they're being told. Lots of people just follow whatever anyone, who they perceive as authority, says. Critical thinking isn't a common trait.