-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
p: pigeonrelated to pigeon messaging codegen toolrelated to pigeon messaging codegen toolpackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.
Description
Minor, but useful enhancement.
Currently, following pigeon class:
class Response {
List<String> details;
}generates following java version:
public static class Response {
private ArrayList details;
public ArrayList getDetails() { return details; }
public void setDetails(ArrayList setterArg) { this.details = setterArg; }
...
}However, from what I see, there is really no reason why details here is specifically ArrayList. It should just be List, which allows developer to pass any kind of list.
Primary use case here are transformation methods, for example Kotlin's list.map {} method which just return ordinary List. At the moment, there is additional overhead of transforming whatever list Kotlin generates into ArrayList.
(This is with Pigeon 0.1.6)
xster
Metadata
Metadata
Assignees
Labels
p: pigeonrelated to pigeon messaging codegen toolrelated to pigeon messaging codegen toolpackageflutter/packages repository. See also p: labels.flutter/packages repository. See also p: labels.