Just out of curiosity:
Java does provide a listOf()
/mapOf()
with 1 argument to create the SingletonList
/SingletonMap
.
Is there a specific reason why common-Kotlin doesn’t provide this optimization?
Or is this just an oversight/skippd for the moment to safe some time?