PackageTrack
Sign in Get early access

cfg-if

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.

1.0.4 1.3B downloads/mo #17 most downloaded on crates.io rust-lang/cfg-if

What this package is like to depend on

Last release 10 months ago

15 Oct 2025

Ships unpredictably

gaps range from 2 months to 4.7 years

Rarely documented

notes for 3 of 15 stable releases

1 version withdrawn

withdrawn after publishing

11 years old

16 releases · first in 2015

1 release in the last 12 months

see the full history below

Release timeline

16 releases · Jul 2015 to Oct 2025
2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026
Release Pre-release Withdrawn

Releases

latest 16
  1. 1.0.4 15 Oct 2025
    Release notes
    • Support cfg(true) and cfg(false) (#99)
    • Set and test a MSRV of 1.32
    • Have a single top-level rule
    Open source →
    Release notes
    • Support cfg(true) and cfg(false) (#99)
    • Set and test a MSRV of 1.32
    • Have a single top-level rule
    Open source →
  2. 1.0.3 19 Aug 2025
    Release notes
    • Revert "Remove @__identity rule."
    Open source →
    Release notes
    • Revert "Remove @__identity rule."
    Open source →
  3. 1.0.2 19 Aug 2025 withdrawn
    Release notes
    • Remove @__identity rule.
    Open source →
    Release notes
    • Remove @__identity rule.
    Open source →
  4. 1.0.1 09 Jun 2025
    Release notes

    Other

    • Remove compiler-builtins from rustc-dep-of-std dependencies
    • Remove redundant configuration from Cargo.toml
    • More readable formatting and identifier names. (#39)
    • Add expanded example to readme (#38)
    Open source →
    Release notes
    • Remove compiler-builtins from rustc-dep-of-std dependencies
    • Remove redundant configuration from Cargo.toml
    • More readable formatting and identifier names. (#39)
    • Add expanded example to readme (#38)
    Open source →
  5. 1.0.0 06 Oct 2020

    Nothing published for this version

  6. 0.1.10 24 Sep 2019

    Nothing published for this version

  7. 0.1.9 15 May 2019

    Nothing published for this version

  8. 0.1.8 15 May 2019

    Nothing published for this version

  9. 0.1.7 04 Mar 2019

    Nothing published for this version

  10. 0.1.6 20 Oct 2018

    Nothing published for this version

  11. 0.1.5 13 Aug 2018

    Nothing published for this version

  12. 0.1.4 27 Jun 2018

    Nothing published for this version

  13. 0.1.3 03 May 2018

    Nothing published for this version

  14. 0.1.2 05 Jul 2017

    Nothing published for this version

  15. 0.1.1 08 Jun 2017

    Nothing published for this version

  16. 0.1.0 08 Jul 2015

    Nothing published for this version

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive