Inspectopedia Help

Suspicious callable reference used as lambda result

Reports lambda expressions with one callable reference.

It is a common error to replace a lambda with a callable reference without changing curly braces to parentheses.


listOf(1,2,3).map { it::toString }

After the quick-fix is applied:


Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for JVM 2023.3


Kotlin, @snapshot@

Last modified: 13 July 2023