Lei Wu
01/09/2020, 8:30 AMobject LogUtil {
fun log(message: String) {
}
}
but export to ios framework, the class defined like this:
*__attribute__*((objc_subclassing_restricted))
*__attribute__*((swift_name("LogUtil")))
*@interface* CommonLogUtil : KotlinBase
+ (*instancetype*)alloc *__attribute__*((unavailable));
+ (*instancetype*)allocWithZone:(*struct* _NSZone *)zone *__attribute__*((unavailable));
+ (*instancetype*)logUtil *__attribute__*((swift_name("init()")));
- (*void*)logMessage:(NSString *)message *__attribute__*((swift_name("log(message:)")));
*@end*;
As code shows that “logMessage” method is not a “class method”,
the expected result maybe like this:
+ (*void*)logMessage:(NSString *)message *__attribute__*((swift_name("log(message:)")));
kpgalligan
01/09/2020, 12:52 PMLogUtil().log(message: "abc")
kpgalligan
01/09/2020, 12:52 PMLei Wu
01/10/2020, 3:49 AM