I have a function that takes in an Array<String?>:
fun doStuff(words: Array<String?>) {
// ...
}
Is there a way I can pass in a Array<String> to this function? As-is the compiler is giving me a "type mismatch" error.
private val SOME_WORDS = arrayOf("I", "want", "to", "use", "these")
doStuff(SOME_WORDS) // throws a type-mismatch error
Preferably I'd like to avoid making SOME_WORDS an arrayOf<String?>(...) if possible.


