Skip to content

Commit 01b1410

Browse files
rolfbjarneCopilot
andcommitted
[CoreMidi] Make MidiUniversalMessage blittable (no explicit layout).
Explicit struct layout (with overlapping union fields) makes a struct non-blittable, which forces the runtime to generate marshaling code and prevents passing the struct by value through a 'delegate* unmanaged' function pointer without overhead. Rewrite MidiUniversalMessage and its variant structs to use sequential blittable layout with opaque storage fields, exposing the native unions through unsafe accessor properties that reinterpret the storage. Also replace fixed buffers / array fields with named byte fields. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 5247eb1 commit 01b1410

2 files changed

Lines changed: 232 additions & 151 deletions

File tree

0 commit comments

Comments
 (0)