Accidental override: The following declarations have the same JVM signature
I'm getting this error in Kotlin in this part: class GitHubRepoAdapter(private val context: Context, private val values: List<GithubRepo>) : ArrayAdapter<GithubRepo>(context, R.layout.list_item, values) { private val context: Context in log it says: Error:(14, 25) Accidental override: The following declarations have the same JVM signature (getContext()Landroid/content/Context;): fun (): Context fun getContext(): Context! I'm not able to see what is causing the problem. This happens because the Kotlin compiler tries to generate a getter for val context declared in your class primary constructor