|
|
|
@ -901,7 +901,7 @@ void ImmutableMessageLiteGenerator::GenerateKotlinExtensions( |
|
|
|
|
"com.google.protobuf.ExtensionLite<$message$, T>): T {\n" |
|
|
|
|
" return if (extension.isRepeated) {\n" |
|
|
|
|
" get(extension as com.google.protobuf.ExtensionLite<$message$, " |
|
|
|
|
"List<*>>) as T\n" |
|
|
|
|
"kotlin.collections.List<*>>) as T\n" |
|
|
|
|
" } else {\n" |
|
|
|
|
" _builder.getExtension(extension)\n" |
|
|
|
|
" }\n" |
|
|
|
@ -914,7 +914,8 @@ void ImmutableMessageLiteGenerator::GenerateKotlinExtensions( |
|
|
|
|
"(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)\n" |
|
|
|
|
"@kotlin.jvm.JvmName(\"-getRepeatedExtension\")\n" |
|
|
|
|
"public operator fun <E : kotlin.Any> get(\n" |
|
|
|
|
" extension: com.google.protobuf.ExtensionLite<$message$, List<E>>\n" |
|
|
|
|
" extension: com.google.protobuf.ExtensionLite<$message$, " |
|
|
|
|
"kotlin.collections.List<E>>\n" |
|
|
|
|
"): com.google.protobuf.kotlin.ExtensionList<E, $message$> {\n" |
|
|
|
|
" return com.google.protobuf.kotlin.ExtensionList(extension, " |
|
|
|
|
"_builder.getExtension(extension))\n" |
|
|
|
|