Problems with error codes:
Too easy to ignore.
Errors and normal return codes get mixed.
Often difficult to pick a distinguished error value, 0, -1?
Problems with exceptions:
Too easy to ignore. How often do you find empty exceptions?
Too many types of exceptions, The Java libraries are particularly guilty of this.
Adding a checked exception can break code all over the universe.
Problems with error codes:
Too easy to ignore.
Errors and normal return codes get mixed.
Often difficult to pick a distinguished error value, 0, -1?
Problems with exceptions:
Too easy to ignore. How often do you find empty exceptions?
Too many types of exceptions, The Java libraries are particularly guilty of this.
Adding a checked exception can break code all over the universe.