|
14 | 14 | ### What's new? |
15 | 15 |
|
16 | 16 | - All user-defined types can now be renamed with the proc-macro `name = "NewName"` attribute (like already supported for methods and constructors) ([#2661](https://github.com/mozilla/uniffi-rs/pull/2661)) |
17 | | -- Objects can export the `Ord` trait, allowing such objects to be ordered ([#2583](https://github.com/mozilla/uniffi-rs/pull/2583)). |
18 | | -- Objects can implement external traits ([#2430](https://github.com/mozilla/uniffi-rs/issues/2430)) |
19 | | -- Procmacros support `#[uniffi(default)]` on a field or `#[uniffi::export(default(arg_name))]` (ie, |
20 | | - without a literal) meaning the default value for the type. Named types can also have a default. |
21 | | - ([#2543](https://github.com/mozilla/uniffi-rs/pull/2543)) |
22 | | -- Custom types support the default value, and specified as its "bridge" type ([#2603](https://github.com/mozilla/uniffi-rs/pull/2603)) |
23 | | -- Custom `enum` and `object` types can be used as error type ([#2658](https://github.com/mozilla/uniffi-rs/pull/2658)) |
24 | | -- Objects can implement external traits ([#2430](https://github.com/mozilla/uniffi-rs/issues/2430)) |
| 17 | +- Enums and Records support exporting uniffi traits (ie, `Display`, `Hash`, `Eq` etc) ([#2555](https://github.com/mozilla/uniffi-rs/issues/2555)) |
| 18 | +- Support for exporting the `Ord` trait, allowing objects to be ordered by Rust ([#2583](https://github.com/mozilla/uniffi-rs/pull/2583)). |
25 | 19 | - `#[uniffi(default)]` literals are now optional - eg, `#[uniffi(default)]` and `#[uniffi(default = 0)]` are equivalent. |
| 20 | + Similarly for args; `#[uniffi::export(default(arg_name))]`. |
26 | 21 | When no literal is specifed, named types (objects, records, etc) can be used as long as they have suitable default values. |
27 | 22 | ([#2543](https://github.com/mozilla/uniffi-rs/pull/2543)). |
28 | 23 | Custom types too ([#2603](https://github.com/mozilla/uniffi-rs/pull/2603)) |
29 | | -- Kotlin: The `NoPointer` placeholder object used to create fake interface instances has been renamed to `NoHandle` |
30 | | -- Python: methods now have typing annotations for return values ([#2625](https://github.com/mozilla/uniffi-rs/issues/2625)) |
31 | | -- Swift: initialization functions now have a stable ordering when using external types. |
32 | | - This makes the generated source files more deterministic. |
| 24 | +- Custom `enum` and `object` types can be used as error type ([#2658](https://github.com/mozilla/uniffi-rs/pull/2658)) |
| 25 | +- Objects can implement external traits ([#2430](https://github.com/mozilla/uniffi-rs/issues/2430)) |
| 26 | +- Fix for external errors when error only used externally ([#2641](https://github.com/mozilla/uniffi-rs/pull/2641)) |
| 27 | +- Kotlin: |
| 28 | + * Switch to JNA direct mapping ([#2229](https://github.com/mozilla/uniffi-rs/pull/2229)) |
| 29 | + * Support throwing external error ([#2629](https://github.com/mozilla/uniffi-rs/pull/2629)) |
| 30 | + * The `NoPointer` placeholder object used to create fake interface instances has been renamed to `NoHandle` |
| 31 | +- Python: |
| 32 | + * Methods now have typing annotations for return values ([#2625](https://github.com/mozilla/uniffi-rs/issues/2625)) |
| 33 | + * Fix relative imports ([#2657](https://github.com/mozilla/uniffi-rs/pull/2657)) |
| 34 | + * Fix shadowing param names with internal variables in Python (#2628/#2645) |
| 35 | +- Swift: |
| 36 | + * All object protocol conformances are public ([#2671](https://github.com/mozilla/uniffi-rs/pull/2671)) |
| 37 | + * Initialization functions now have a stable ordering when using external types. |
| 38 | + This makes the generated source files deterministic. |
33 | 39 |
|
34 | 40 | ### ⚠️ Breaking Changes for external bindings authors ⚠️ |
35 | 41 |
|
|
0 commit comments