Skip to content

Commit 259ffbf

Browse files
committed
internal: pin_data: support tuple struct projections
Add plumbing for tuple struct support to `#[pin_data]` by generating tuple struct projections and tuple-aware pin-data metadata. Keep the projection API native to Rust tuple structs, so projected fields are accessed as `.0`, `.1`, etc. instead of introducing synthetic public field names. Signed-off-by: Mohamad Alsadhan <mo@sdhn.cc>
1 parent d5ac5a8 commit 259ffbf

9 files changed

Lines changed: 488 additions & 112 deletions

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
### Added
1111

12+
- Support tuple structs in `#[pin_data]`, including tuple struct projections.
1213
- `[pin_]init_scope` functions to run arbitrary code inside of an initializer.
1314
- `&'static mut MaybeUninit<T>` now implements `InPlaceWrite`. This enables users to use external
1415
allocation mechanisms such as `static_cell`.

0 commit comments

Comments
 (0)