Relative Content

Tag Archive for exceptions

How do you hide error handling? [duplicate]

This question already has answers here: Using “catching exceptions” to improve readability, Good or Bad? (4 answers) Closed 11 years ago. Many people consider exceptions to be a problem because they create invisible paths through your code. For example in this snippet: function writeToFile(text, filename): filehandle = open(filename) foreach line in text: filehandle.write(line) filehandle.close() The […]

How do you hide error handling? [duplicate]

This question already has answers here: Using “catching exceptions” to improve readability, Good or Bad? (4 answers) Closed 11 years ago. Many people consider exceptions to be a problem because they create invisible paths through your code. For example in this snippet: function writeToFile(text, filename): filehandle = open(filename) foreach line in text: filehandle.write(line) filehandle.close() The […]

How do you hide error handling? [duplicate]

This question already has answers here: Using “catching exceptions” to improve readability, Good or Bad? (4 answers) Closed 11 years ago. Many people consider exceptions to be a problem because they create invisible paths through your code. For example in this snippet: function writeToFile(text, filename): filehandle = open(filename) foreach line in text: filehandle.write(line) filehandle.close() The […]

How do you hide error handling? [duplicate]

This question already has answers here: Using “catching exceptions” to improve readability, Good or Bad? (4 answers) Closed 11 years ago. Many people consider exceptions to be a problem because they create invisible paths through your code. For example in this snippet: function writeToFile(text, filename): filehandle = open(filename) foreach line in text: filehandle.write(line) filehandle.close() The […]

When is a catch clause empty [duplicate]

This question already has answers here: Is it ever ok to have an empty catch statement? (15 answers) Closed 11 years ago. I saw lots of questions and explanations regarding empty catch clauses but I was never actually sure what “empty” means. Is a catch clause like this empty? It clearly isn’t empty for the […]

When is a catch clause empty [duplicate]

This question already has answers here: Is it ever ok to have an empty catch statement? (15 answers) Closed 11 years ago. I saw lots of questions and explanations regarding empty catch clauses but I was never actually sure what “empty” means. Is a catch clause like this empty? It clearly isn’t empty for the […]