Skip to content

mark MidiSysExEvent::new as unsafe#83

Open
edwloef wants to merge 2 commits into
prokopyl:mainfrom
edwloef:unsafe-midi-sysex-constructor
Open

mark MidiSysExEvent::new as unsafe#83
edwloef wants to merge 2 commits into
prokopyl:mainfrom
edwloef:unsafe-midi-sysex-constructor

Conversation

@edwloef
Copy link
Copy Markdown
Contributor

@edwloef edwloef commented May 4, 2026

... and adjust the safety documentation to match the clap headers (ref. events.h)

@edwloef
Copy link
Copy Markdown
Contributor Author

edwloef commented May 4, 2026

I'm fairly sure it would be sound to add a safe new_static constructor, that takes &'static [u8] for the buffer. Do you think that would be a useful addition here? I honestly have no clue about how MIDI SysEx event data might look, so I can't know how common one without any dynamic data might be, but it would provide a safe interface to construct one.

@edwloef edwloef force-pushed the unsafe-midi-sysex-constructor branch from 93e2803 to acbb123 Compare May 4, 2026 21:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant