sweekt
sweekt copied to clipboard
🍭 Some sugar to sweeten Kotlin development.
[](https://renovatebot.com) Welcome to [Renovate](https://togithub.com/renovatebot/renovate)! This is an onboarding PR to help you understand and configure settings before regular Pull Requests begin. 🚦 To activate Renovate, merge this Pull Request....
您好!我是一名kotlin compiler的初学者,请问您可以告诉我怎么使用kotlin compiler去继承一个父类吗?比如: open class A(){} @随意的注解名 class B(){} 被注解的类可以变成: class B:A(){} 十分感谢!
Update Gradle Wrapper to 7.5.1. Read the release notes: https://docs.gradle.org/7.5.1/release-notes.html --- The checksums of the Wrapper JAR and the distribution binary have been successfully verified. - Gradle release: `7.5.1` -...
Example: ```kotlin val list = listOf(...) // List instance never be Array list.cast() list.castOrNull() ```
Temporary solving https://youtrack.jetbrains.com/issue/KT-13108#focus=Comments-27-5474923.0-0 ```kotlin fun save(data: Union4): UnionType { var result = Result(false) when { data is String -> { ... } data is Int -> { ... } data...
https://youtrack.jetbrains.com/issue/KT-15555 ```kotlin var property: Any get() = suspendGetter { // suspended } set(value) = suspendSetter { // suspended } ``` **Diagnosis:** ``` @SuspendGetter @SuspendSetter ```
Suppress `EqualsOrHashCode` when the class marked with **@LazyInit** > Class has 'equals()' defined but does not define 'hashCode()'
This is meaningless, because the class will directly initialize the property when calling the constructor: Meaningless `b`: ```kotlin class Foo(a: Boolean, @LazyInit val b: String = "String") Foo(true) // in...