about summary refs log tree commit diff
path: root/library/core/src/array
diff options
context:
space:
mode:
authorUrgau <urgau@numericable.fr>2024-12-13 19:53:04 +0100
committerUrgau <urgau@numericable.fr>2025-01-20 18:35:32 +0100
commit8e615024844030e5148ee6d22efc5bcaa48c5311 (patch)
tree7855ce7297ce1f339b4d1c6cf6a3d49bc6633f48 /library/core/src/array
parent0f30662147edad559ef7f8ec57cc4d17f4ba5dc2 (diff)
downloadrust-8e615024844030e5148ee6d22efc5bcaa48c5311.tar.gz
rust-8e615024844030e5148ee6d22efc5bcaa48c5311.zip
core: add `#![warn(unreachable_pub)]`
Diffstat (limited to 'library/core/src/array')
-rw-r--r--library/core/src/array/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs
index 2ae5ded1fd5..ba61679564a 100644
--- a/library/core/src/array/mod.rs
+++ b/library/core/src/array/mod.rs
@@ -893,7 +893,7 @@ impl<T> Guard<'_, T> {
     ///
     /// No more than N elements must be initialized.
     #[inline]
-    pub unsafe fn push_unchecked(&mut self, item: T) {
+    pub(crate) unsafe fn push_unchecked(&mut self, item: T) {
         // SAFETY: If `initialized` was correct before and the caller does not
         // invoke this method more than N times then writes will be in-bounds
         // and slots will not be initialized more than once.