Closed
Description
Problem
I'm trying to use multi-injection to provide 2 different maps of ComplexKey -> Provider<Type>
. This works great as long as the ComplexKey
does not have a parameter that is also a Complex Key. This error ONLY occurs when the nested value is requested as an array, not if requested as a single value.
Snippet
// This works perfectly
@MapKey(unwrapValues = false)
annotation class TopKey(val value: String, val otherValue: Boolean)
// This fails
@MapKey(unwrapValues = false)
annotation class TopKey(val value: String, val otherValues: Array<NestedKey> = [])
@MapKey(unwrapValues = false)
annotation class NestedKey(val value: String, val otherValue: Boolean)
// This also works
@MapKey(unwrapValues = false)
annotation class TopKey(val value: String, val otherValues: NestedKey = NestedKey("", false))
@MapKey(unwrapValues = false)
annotation class NestedKey(val value: String, val otherValue: Boolean)
Repo
I've created this small repo to repro https://github.com/martofeld/dagger-multibinding-issu
Metadata
Metadata
Assignees
Labels
No labels