I have an extension generic function, declared as ...
# announcements
k
I have an extension generic function, declared as such:
Copy code
inline fun <reified TCallback, TParent> TParent.initCallback()
        where TParent : Fragment, TParent : IHasCallback<TCallback> { ... }
I then want to call it inside a class that implements
IHasCallback<Something>
and inherits
Fragment
. I even get code completion, but it won't compile saying
Error:(40, 14) Unresolved reference. None of the following candidates is applicable because of receiver type mismatch:
public inline fun <reified TCallback, TParent : Fragment> SearchSaveDialogFragment.initCallback(): Unit where TParent :
IHasCallback<SearchSaveDialogFragmentCallbacks> defined in my.app.name