Comment by vips7L
2 days ago
All modern languages are adopting a checked error system: Rust, Swift, Kotlin, Zig, Gleam; they all have some type of error you must handle.
The problem with Java is that they haven’t added the syntax to make dealing with those errors easy. It’s boiler plate hell.
Yeah, unwrapping a Result in Rust can often be done via a single character, the chainable `?` operator.
That’s not the only issue, though: Java also shunts both checked and unchecked exceptions through the same mechanism, conflating them. It’s no wonder that Java’s problematic implementation of checked exceptions has poisoned people against the concept.