Inspectopedia Help

No Hard Kotlin Keywords

No Hard Kotlin Keywords

Do not use Kotlin’s hard keywords as the name of methods or fields. These require the use of backticks to escape when calling from Kotlin. Soft keywords, modifier keywords, and special identifiers are allowed.

For example, ActionEvent's getWhen() method requires backticks when used from Kotlin: val timestamp = event.`when`

Issue id: NoHardKeywords

https://android.github.io/kotlin-guides/interop.html#no-hard-keywords

Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for Android 2023.3, Qodana for JVM 2023.3

Plugin:

Android, 2022.3.1 Beta 2

Last modified: 13 July 2023