tag | 66173d421b74b77173dd8ec40fea490a7c41d965 | |
---|---|---|
tagger | The Android Open Source Project <initial-contribution@android.com> | Mon Apr 10 19:18:39 2023 -0700 |
object | 8499f0874c123a905c185bc07017777b9a743406 |
Android Platform 13.0.0 Release 6 (TPM1.230223.001)
commit | 8499f0874c123a905c185bc07017777b9a743406 | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Tue Nov 01 21:30:15 2022 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Tue Nov 01 21:30:15 2022 +0000 |
tree | 922148d864e3db4510c9ac0118a0c1a4a95056de | |
parent | 40cfd6ae1e4d4496c28ba35907a3f59e7522a2cb [diff] | |
parent | c3803a33d3038f46c29772974a48a30560dfc0f1 [diff] |
Snap for 9239618 from c3803a33d3038f46c29772974a48a30560dfc0f1 to tm-platform-release Change-Id: I431a828e6826b70c08dcd3294aa14b18a6c9e7e3
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.
[dependencies] cfg-if = "0.1"
cfg_if::cfg_if! { if #[cfg(unix)] { fn foo() { /* unix specific functionality */ } } else if #[cfg(target_pointer_width = "32")] { fn foo() { /* non-unix, 32-bit functionality */ } } else { fn foo() { /* fallback implementation */ } } } fn main() { foo(); }
This project is licensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in cfg-if
by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.