Clean up deprecations - #8300
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughThe changes replace the deprecated Android ChangesDeprecation cleanup
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
592a6bd to
23d0d5e
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@crates/host_env/src/resource.rs`:
- Around line 36-37: Update the Android-only RLIM_NLIMITS constant in
resource.rs to use libc::c_int, matching libc::RLIM_NLIMITS and the type
expected by crates/stdlib/src/resource.rs; leave its value and other platform
definitions unchanged.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yml
Review profile: CHILL
Plan: Pro
Run ID: 9f309701-c2aa-4bac-959c-2239e0587e44
📒 Files selected for processing (3)
crates/host_env/src/resource.rscrates/vm/src/builtins/function.rscrates/vm/src/builtins/type.rs
23d0d5e to
50939de
Compare
fetch_update() in atomic namespace is in the deprecation stage.
Define a new const, RLIM_NLIMITS instead of libc::RLIM_NLIMITS in order to clean up the deprecated const and to prevent breaking API where the const is still used.
50939de to
4925517
Compare
moreal
left a comment
There was a problem hiding this comment.
Thank you!
Refs
https://docs.rs/libc/latest/aarch64-linux-android/libc/constant.RLIM_NLIMITS.html
👎Deprecated since 0.2.64:
Not stable across OS versions
https://doc.rust-lang.org/std/sync/atomic/type.AtomicU64.html#method.fetch_update
👎Deprecating in 1.99.0:
renamed totry_updatefor consistency
host_envandvmcrates. #8297Summary
This PR has two commits that replace the deprecated methods in libc with new APIs or define a new const value due to compatibility.
Summary by CodeRabbit