Kotlin's Rich Errors: Native, Typed Errors Without Exceptions
Summary
Kotlin's Rich Errors introduces union types to make error handling part of the type system, moving away from exceptions toward explicit error results. The article compares Rich Errors to existing patterns like Result and Either, notes its experimental status, and discusses potential benefits such as exhaustiveness, composability, and safer refactors. It frames this as a significant step toward native, typed errors in Kotlin.