4 ms·
The big problem with Java's model is that exceptions aren't part of the type system: they're that whole separate thing that is applied to methods, but it's not
by int_19h 7y ago
The big problem with Java's model is that exceptions aren't part of the type system: they're that whole separate thing that is applied to methods, but it's not a part of that method's type in any meaningful sense. This means that it's impossible to write a higher-order function along the lines of "map" or "filter" that would properly propagate exceptions, because there's no way to capture the throws-clause of the predicate and surface it on the HOF itself.
- hota_mazi 7y ago`> The big problem with Java's model is that exceptions aren't part of the type system They are. To the extent that the checked exceptions that a method can throw are part of the method signature (as all error cases should). I have no idea what you mean by "exceptions aren't part of the type system".