-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Experimentally add ffi_const
and ffi_pure
extern fn attributes
#71718
Conversation
Some changes occurred in diagnostic error codes |
Unfortunately I'm too swamped with non-Rust work to take on any more reviews at this time. |
☔ The latest upstream changes (presumably #69274) made this pull request unmergeable. Please resolve the merge conflicts. |
☔ The latest upstream changes (presumably #71828) made this pull request unmergeable. Please resolve the merge conflicts. |
☔ The latest upstream changes (presumably #69171) made this pull request unmergeable. Please resolve the merge conflicts. |
Introduce function attribute corresponding to the `const`/`pure` attributes supported by GCC, clang and other compilers. Based on the work of gnzlbg <[email protected]>.
Based on the work of gnzlbg <[email protected]>.
…able book Based on the work of gnzlbg <[email protected]>.
@bors r+ |
📌 Commit a114a23 has been approved by |
Experimentally add `ffi_const` and `ffi_pure` extern fn attributes Add FFI function attributes corresponding to clang/gcc/... `const` and `pure`. Rebased version of rust-lang#58327 by @gnzlbg with the following changes: - Switched back from the `c_ffi_const` and `c_ffi_pure` naming to `ffi_const` and `ffi_pure`, as I agree with rust-lang#58327 (comment) and this nicely aligns with `ffi_returns_twice` - (Hopefully) took care of all of @hanna-kruppe's change requests in the original PR r? @hanna-kruppe
☀️ Test successful - checks-azure |
Add FFI function attributes corresponding to clang/gcc/...
const
andpure
.Rebased version of #58327 by @gnzlbg with the following changes:
c_ffi_const
andc_ffi_pure
naming toffi_const
andffi_pure
, as I agree with Experimentally addffi_const
andffi_pure
extern fn attributes #58327 (comment) and this nicely aligns withffi_returns_twice
r? @hanna-kruppe