diff --git a/crates/wdk-build/src/lib.rs b/crates/wdk-build/src/lib.rs index 6b6fff7c2..87450120f 100644 --- a/crates/wdk-build/src/lib.rs +++ b/crates/wdk-build/src/lib.rs @@ -301,7 +301,15 @@ impl Config { }) } - fn emit_check_cfg_settings() { + /// Emit `cargo::rustc-check-cfg` directives corresponding to all the + /// possible `rustc-cfg` settings `wdk_build` could emit + /// + /// This is useful in situations where a library may not have a valid WDK + /// config available during build. This function is not needed if the build + /// was already configured via [`configure_wdk_binary_build`], + /// [`configure_wdk_library_build`], or + /// [`configure_wdk_library_build_and_then`] + pub fn emit_check_cfg_settings() { for (cfg_key, allowed_values) in EXPORTED_CFG_SETTINGS.iter() { let allowed_cfg_value_string = allowed_values.iter().fold(String::new(), |mut acc, value| {