Added guards to individual APIs

This commit is contained in:
Andres Oliva
2023-10-11 23:25:13 +02:00
parent b6c0ddb7df
commit cd68f85501
3 changed files with 86 additions and 12 deletions

View File

@ -5,7 +5,7 @@ use crate::interrupt;
// I2C V2 is gated on the `time` feature because timing facilities are necessary
// to provide timeout functionality in order to prevent some APIs from stalling indefinitely
#[cfg_attr(i2c_v1, path = "v1.rs")]
#[cfg_attr(all(i2c_v2, feature = "time"), path = "v2.rs")]
#[cfg_attr(i2c_v2, path = "v2.rs")]
mod _version;
pub use _version::*;