release
alert
Auto-detect
Apple App Store
Rust Crate (Cargo)
Chocolatey Package
Docker Image
Debian Package (Bookworm)
Go Module
Ruby GEM
GitHub Repository
GitLab Repository
Maven Central
NPM Package
NuGet Package
Packagist Package
Python Package (PyPI)
VS Code Extension
WordPress Plugin
Search
/
Sign in
rust-lang/cfg-if
GitHub
github.com
Releases
15
Frequency
7 months 4 days
Last Release
8 months ago
Wednesday, 15 October 2025, 08:12
Stars
637
A if/elif-like macro for Rust #[cfg] statements
Log in to subscribe
Releases
15
Links
1
Collections
0
Linked projects
cfg-if
Crates.io
A macro to ergonomically define an item depending on a large number of #[cfg] parameters. Structured like an if-else chain, the first matching branch is the item that gets emitted.