Fix Windows GNU unwinding bindings for Rust 2024#1640
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| /// Forwards `rsbegin`'s registration hook to libunwind. | ||
| #[no_mangle] | ||
| #[unsafe(no_mangle)] | ||
| pub unsafe extern "C" fn ___register_frame_info(eh_frame: *const u8, object: *mut c_void) { | ||
| __register_frame_info(eh_frame, object); | ||
| unsafe { | ||
| __register_frame_info(eh_frame, object); | ||
| } |
There was a problem hiding this comment.
Document new unsafe blocks to satisfy Clippy
The new unsafe { __register_frame_info(...) } block was added to satisfy Rust‑2024’s unsafe‑op requirements, but this crate has #![deny(clippy::undocumented_unsafe_blocks)]. Without a // SAFETY: justification the lint will emit an error and cargo clippy --workspace --all-targets -- -D warnings will fail. The block in ___deregister_frame_info below has the same issue. Please add brief safety comments or restructure to avoid the block.
Useful? React with 👍 / 👎.
Summary
no_mangleuses and unsafe calls to satisfy the new lintsTesting
https://chatgpt.com/codex/tasks/task_e_6902d5f7c7b48323b924f789a6e425b6