@@ -216,8 +216,10 @@ it as a return type for generic business logic.
216216- The Kotlin team admits its "half-baked" and discourages use for "domain-specific error conditions".
217217- The Kotlin team do not use it, and are sending increasingly mixed messages on how users should be dealing with
218218 domain-specific errors.
219- - The Kotlin team keep inventing their own domain-specific versions, e.g. [ ` ChannelResult ` ] [ ChannelResult ] ) in the
220- coroutines library, thus proving the need for such a type but lacking commitment to a standardised solution.
219+ - JetBrains keep inventing their own domain-specific versions: [ one] [ MetadataDeclarationsComparator ] ,
220+ [ two] [ parametersMap ] , [ three] [ ChannelResult ] , [ four] [ LineStatusTrackerManager ] ,
221+ [ five] [ LazyLoadingAccountsDetailsProvider ] , [ six] [ VcsCodeVisionProvider ] - thus proving the need for such a type but
222+ lacking commitment to a standardised solution.
221223- It was initially unusable as a return type and usage was discouraged. This restriction was then lifted and users
222224 guided towards context receivers. Context receivers were abandoned in favour of the (still experimental) context
223225 parameters. Rich errors have been proposed to supersede context parameters by providing a language-level solution.
@@ -358,7 +360,12 @@ information and licensing terms.
358360[ stdlib-result-return-type-lifted ] : https://discuss.kotlinlang.org/t/state-of-kotlin-result-vs-kotlin-result/21103/5
359361[ stdlib-result-keep ] : https://github.com/Kotlin/KEEP/blob/master/proposals/stdlib/result.md#error-handling-style-and-exceptions
360362[ stdlib-result-runCatching ] : https://github.com/JetBrains/kotlin/blob/v2.2.20/libraries/stdlib/src/kotlin/util/Result.kt#L144
363+ [ MetadataDeclarationsComparator ] : https://github.com/JetBrains/kotlin/blob/c811992b611b8a725b6b55dafa574a0b145b5da3/native/commonizer/src/org/jetbrains/kotlin/commonizer/metadata/utils/MetadataDeclarationsComparator.kt#L43
364+ [ parametersMap ] : https://github.com/JetBrains/kotlin/blob/c811992b611b8a725b6b55dafa574a0b145b5da3/compiler/cli/cli-common/src/org/jetbrains/kotlin/utils/parametersMap.kt#L60
361365[ ChannelResult ] : https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.channels/-channel-result/
366+ [ LineStatusTrackerManager ] : https://github.com/JetBrains/intellij-community/blob/d73a081b09fcb0f53308352a57ad54c0721f0443/platform/vcs-impl/src/com/intellij/openapi/vcs/impl/LineStatusTrackerManager.kt#L1406
367+ [ LazyLoadingAccountsDetailsProvider ] : https://github.com/JetBrains/intellij-community/blob/d73a081b09fcb0f53308352a57ad54c0721f0443/platform/collaboration-tools/src/com/intellij/collaboration/auth/ui/LazyLoadingAccountsDetailsProvider.kt#L92
368+ [ VcsCodeVisionProvider ] : https://github.com/JetBrains/intellij-community/blob/d73a081b09fcb0f53308352a57ad54c0721f0443/platform/vcs-impl/lang/src/com/intellij/codeInsight/hints/VcsCodeVisionProvider.kt#L287
362369[ CancellationException ] : https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.coroutines.cancellation/-cancellation-exception/
363370[ rich-hickey-maybe-not ] : https://www.youtube.com/watch?v=YR5WdGrpoug&t=657s
364371
0 commit comments