Crate features / objc2
Feature flags · objc2 0.6.5 · from crates.io 2026-10-24
objc2 features: what each one does, and the line to copy
Short answerobjc2 0.6.5 has 28 features. By default it turns on std; add default-features = false to start from nothing. It needs Rust 1.71 or newer.
Pick features
Every feature
| Feature | In default | Turns on |
|---|---|---|
alloc | objc2-encode/alloc | |
catch-all | exception | |
disable-encoding-assertions | nothing else (a switch the code checks) | |
exception | dep:objc2-exception-helper | |
gnustep-1-7 | unstable-static-class, objc2-exception-helper?/gnustep-1-7 | |
gnustep-1-8 | gnustep-1-7, objc2-exception-helper?/gnustep-1-8 | |
gnustep-1-9 | gnustep-1-8, objc2-exception-helper?/gnustep-1-9 | |
gnustep-2-0 | gnustep-1-9, objc2-exception-helper?/gnustep-2-0 | |
gnustep-2-1 | gnustep-2-0, objc2-exception-helper?/gnustep-2-1 | |
objc2-proc-macros | nothing else (a switch the code checks) | |
relax-sign-encoding | nothing else (a switch the code checks) | |
relax-void-encoding | nothing else (a switch the code checks) | |
std | yes | alloc, objc2-encode/std |
unstable-apple-new | nothing else (a switch the code checks) | |
unstable-arbitrary-self-types | nothing else (a switch the code checks) | |
unstable-autoreleasesafe | nothing else (a switch the code checks) | |
unstable-coerce-pointee | nothing else (a switch the code checks) | |
unstable-compiler-rt | gnustep-1-7 | |
unstable-darwin-objc | nothing else (a switch the code checks) | |
unstable-gnustep-strict-apple-compat | gnustep-1-7 | |
unstable-objfw | nothing else (a switch the code checks) | |
unstable-requires-macos | nothing else (a switch the code checks) | |
unstable-static-class | dep:objc2-proc-macros | |
unstable-static-class-inlined | unstable-static-class | |
unstable-static-sel | dep:objc2-proc-macros | |
unstable-static-sel-inlined | unstable-static-sel | |
unstable-winobjc | gnustep-1-8 | |
verify | nothing else (a switch the code checks) |
dep:x turns on the optional dependency x; x/y turns on feature y of dependency x (with ?, only if x is already on).
MSRV history
The minimum Rust version objc2 declares (rust-version), and the release that changed it:
- 0.3.0-beta.5 (2023-02-07): Rust 1.60
- 0.3.0-beta.3.patch-leaks (2023-03-13): no rust-version declared
- 0.4.0 (2023-06-20): Rust 1.60
- 0.6.0 (2025-01-22): Rust 1.71
- 0.5.3 (2026-10-05): Rust 1.60
- 0.6.5 (2026-10-05): Rust 1.71
Stuck on an older compiler? Pin the last version that supports it, for example cargo update -p objc2 --precise <version>, or use resolver 3, which picks compatible versions for you.
More on objc2
Real downloads, dependents and alternatives: objc2 crate data (607K real downloads a day, 1,193 dependents).
docs.rs feature list · crates.io · license MIT · edition 2021
Up next
Before you depend on itobjc2 crate dataReal downloads, dependents, alternatives.Read it next →Did this answer your question?