Fixes type mismatch (in Kotlin M10)

Change return type to have an explicit "out" parameter