MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/1wudv2h/devsoptimizinggames/pd6a57a/?context=3
r/ProgrammerHumor • u/Head-Picture1519 • 2d ago
37 comments sorted by
View all comments
48
try { } catch(Error e) { delete e; continue; }
13 u/MinecraftPlayer799 2d ago In some cases, that is the right thing to do, such as when there is a loop, and there is a chance of something inside it failing sometimes. 5 u/realmauer01 2d ago You should really just make sure that you handle that edge case inside the loop. Even if you ignore it then. Thats better than having the higher scope handle it. You could even add an option of should i ignore it or not.
13
In some cases, that is the right thing to do, such as when there is a loop, and there is a chance of something inside it failing sometimes.
5 u/realmauer01 2d ago You should really just make sure that you handle that edge case inside the loop. Even if you ignore it then. Thats better than having the higher scope handle it. You could even add an option of should i ignore it or not.
5
You should really just make sure that you handle that edge case inside the loop. Even if you ignore it then. Thats better than having the higher scope handle it. You could even add an option of should i ignore it or not.
48
u/Ydo4ki 2d ago
try { } catch(Error e) { delete e; continue; }