native
native copied to clipboard
Dart packages related to FFI and native assets bundling.
Generated bindings for C enum: ``` enum ENUM_NAME_T { VALUE_0(0), VALUE_1(1), VALUE_2(2), VALUE_3(3); final int value; const ENUM_NAME_T (this.value); static ENUM_NAME_T fromValue(int value) => switch (value) { 0 => VALUE_0,...
This is a prototype of swiftgen, and an example program that uses the Swift `AVAudioPlayer` API to play some audio from Dart. [`example/generate_code.dart`](https://github.com/dart-lang/native/pull/1367/files#diff-f4c14bb7f06a6e1209e852c437da42f6f335379188a8658759949b823da8adfc) uses swiftgen to generate Dart bindings like...
If a class or struct defines an initializer, we need to generate a corresponding intializer on the wrapper object. If it doesn't define an initializer, we need to define a...
Like ffigen, swift2objc should have config options that let the user choose which APIs they want to generate wrappers for. Real Apple APIs have so many classes and methods that...
Tracking bug for swiftgen MVP Depends on [swift2objc MVP](https://github.com/dart-lang/native/issues/1143)
```Swift func greet(name: String) -> String { let greeting = "Hello, \(name)!" return greeting } ``` The wrapper function will need to convert all the arguments and results to their...
This is the same pattern I'm planning to use in ffigen: #1259
Build hooks are per OS/arch. However, if assets are identical across multiple invocations, and the work to produce those assets is non-trivial, such work should be shared. Examples: * Data...
Show progress messages, fixes https://github.com/dart-lang/sdk/issues/53732 for `dartdev`. See also https://dart-review.googlesource.com/c/sdk/+/378680 cc @craiglabenz, something like this would have to be implemented in Flutter as well. --- - [x] I’ve reviewed the...