about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2022-02-21 19:36:55 +0100
committerGitHub <noreply@github.com>2022-02-21 19:36:55 +0100
commited3530925e8ddad97b152274948675a3eb8bb6ae (patch)
treece1bf37cf5506b3f62aad8c653205e84e6053188
parent9157775152de849681105fbf6752135cd1b7d1e5 (diff)
parent910d46fd60686e031e82ee87dec14f8002f5c8f3 (diff)
downloadrust-ed3530925e8ddad97b152274948675a3eb8bb6ae.tar.gz
rust-ed3530925e8ddad97b152274948675a3eb8bb6ae.zip
Rollup merge of #94220 - GuillaumeGomez:miniz-oxide-decl, r=Amanieu
Correctly handle miniz_oxide extern crate declaration

Fixes https://github.com/rust-lang/rust/issues/94219.

Follow-up of https://github.com/rust-lang/rust/pull/94122.

The `miniz_oxide` dependency is optional and therefore should allow be "imported" when it makes sense.

r? `@ivmarkov`
-rw-r--r--library/std/src/lib.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/library/std/src/lib.rs b/library/std/src/lib.rs
index 2628afd4237..5dc586d3a2a 100644
--- a/library/std/src/lib.rs
+++ b/library/std/src/lib.rs
@@ -366,6 +366,7 @@ extern crate unwind;
 
 #[doc(masked)]
 #[allow(unused_extern_crates)]
+#[cfg(feature = "miniz_oxide")]
 extern crate miniz_oxide;
 
 // During testing, this crate is not actually the "real" std library, but rather