Mark
09/09/2026, 2:19 PMArgument type mismatch: actual type is 'String', but '() -> String' was expected.
Here are the relevant code:
interface FooLogger {
fun logw(message: String, t: Throwable? = null)
fun logw(lazyMessage: () -> String)
companion object {
operator fun invoke(name: String): FooLogger = FooLoggerBridge(name)
}
}
internal object ModuleLogger: FooLogger by FooLogger("BarModule")
I assume it's something to do with the way this ModuleLogger implements FooLogger
EDIT: interestingly, if I use ModuleLogger.logw (instead of logw with import), it doesn't have a problem.