From 93e5e6cb95bde4ca520c163e592a766d558bd1aa Mon Sep 17 00:00:00 2001 From: Luc <47307392+LucDrenth@users.noreply.github.com> Date: Wed, 22 Jan 2025 00:24:05 +0100 Subject: [PATCH] fix double comment characters (#17484) # Objective - Improve docs by removing duplicate comment characters - Fixes #17483 ## Solution - Replaced `/// ///` with `///` --- crates/bevy_ecs/src/change_detection.rs | 4 ++-- crates/bevy_ecs/src/entity/hash_map.rs | 2 +- crates/bevy_ecs/src/system/query.rs | 4 ++-- crates/bevy_ecs/src/system/system_param.rs | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/bevy_ecs/src/change_detection.rs b/crates/bevy_ecs/src/change_detection.rs index b486be555d8f4..414faa8fde885 100644 --- a/crates/bevy_ecs/src/change_detection.rs +++ b/crates/bevy_ecs/src/change_detection.rs @@ -675,7 +675,7 @@ impl_debug!(Res<'w, T>, Resource); /// If you need a shared borrow, use [`Res`] instead. /// /// This [`SystemParam`](crate::system::SystemParam) fails validation if resource doesn't exist. -/// /// This will cause a panic, but can be configured to do nothing or warn once. +/// This will cause a panic, but can be configured to do nothing or warn once. /// /// Use [`Option>`] instead if the resource might not always exist. pub struct ResMut<'w, T: ?Sized + Resource> { @@ -736,7 +736,7 @@ impl<'w, T: Resource> From> for Mut<'w, T> { /// over to another thread. /// /// This [`SystemParam`](crate::system::SystemParam) fails validation if non-send resource doesn't exist. -/// /// This will cause a panic, but can be configured to do nothing or warn once. +/// This will cause a panic, but can be configured to do nothing or warn once. /// /// Use [`Option>`] instead if the resource might not always exist. pub struct NonSendMut<'w, T: ?Sized + 'static> { diff --git a/crates/bevy_ecs/src/entity/hash_map.rs b/crates/bevy_ecs/src/entity/hash_map.rs index bcb415f7b973c..d7635401418e9 100644 --- a/crates/bevy_ecs/src/entity/hash_map.rs +++ b/crates/bevy_ecs/src/entity/hash_map.rs @@ -149,7 +149,7 @@ impl IntoIterator for EntityHashMap { /// An iterator over the keys of a [`EntityHashMap`] in arbitrary order. /// The iterator element type is `&'a Entity`. /// -/// /// This struct is created by the [`keys`] method on [`EntityHashMap`]. See its documentation for more. +/// This struct is created by the [`keys`] method on [`EntityHashMap`]. See its documentation for more. /// /// [`keys`]: EntityHashMap::keys pub struct Keys<'a, V, S = EntityHash>(hash_map::Keys<'a, Entity, V>, PhantomData); diff --git a/crates/bevy_ecs/src/system/query.rs b/crates/bevy_ecs/src/system/query.rs index 1db5b22ef5dfe..dbeaa98c48a23 100644 --- a/crates/bevy_ecs/src/system/query.rs +++ b/crates/bevy_ecs/src/system/query.rs @@ -1902,7 +1902,7 @@ impl<'w, 'q, Q: QueryData, F: QueryFilter> From<&'q mut Query<'w, '_, Q, F>> /// [System parameter] that provides access to single entity's components, much like [`Query::single`]/[`Query::single_mut`]. /// /// This [`SystemParam`](crate::system::SystemParam) fails validation if zero or more than one matching entity exists. -/// /// This will cause a panic, but can be configured to do nothing or warn once. +/// This will cause a panic, but can be configured to do nothing or warn once. /// /// Use [`Option>`] instead if zero or one matching entities can exist. /// @@ -1938,7 +1938,7 @@ impl<'w, D: QueryData, F: QueryFilter> Single<'w, D, F> { /// [System parameter] that works very much like [`Query`] except it always contains at least one matching entity. /// /// This [`SystemParam`](crate::system::SystemParam) fails validation if no matching entities exist. -/// /// This will cause a panic, but can be configured to do nothing or warn once. +/// This will cause a panic, but can be configured to do nothing or warn once. /// /// Much like [`Query::is_empty`] the worst case runtime will be `O(n)` where `n` is the number of *potential* matches. /// This can be notably expensive for queries that rely on non-archetypal filters such as [`Added`](crate::query::Added) or [`Changed`](crate::query::Changed) diff --git a/crates/bevy_ecs/src/system/system_param.rs b/crates/bevy_ecs/src/system/system_param.rs index ae4cd0b9366fe..b475233f8c93e 100644 --- a/crates/bevy_ecs/src/system/system_param.rs +++ b/crates/bevy_ecs/src/system/system_param.rs @@ -1397,7 +1397,7 @@ unsafe impl SystemParam for Deferred<'_, T> { /// over to another thread. /// /// This [`SystemParam`] fails validation if non-send resource doesn't exist. -/// /// This will cause a panic, but can be configured to do nothing or warn once. +/// This will cause a panic, but can be configured to do nothing or warn once. /// /// Use [`Option>`] instead if the resource might not always exist. pub struct NonSend<'w, T: 'static> {