Js code:
function Ctrl(scope, filter) {
scope.a = filter("abc");
}
I tried to write some Kotlin code like this:
native trait Filter {
}
native trait Scope {
var a:String
}
fun Ctrl(scope:Scope, filter:Filter) {
scope.a = filter(“abc”) // !!! how to declare this “()” method in trait Filter?
}
You can see there is a "filter("abc")", it can be understood as "filter.call(this, "abc")". How to declare a proper method for it?