Skip to content

Commit 8aaa04b

Browse files
zachs18Amanieu
andauthored
Apply suggestions from code review
Co-authored-by: Amanieu d'Antras <[email protected]>
1 parent 06ec7a7 commit 8aaa04b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Diff for: library/std/src/sync/mutex.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ impl<'a, T: ?Sized> MutexGuard<'a, T> {
612612
F: FnOnce(&mut T) -> &mut U,
613613
U: ?Sized,
614614
{
615-
// SAFETY: the conditions of `MutedGuard::new` were satisfied when the original guard
615+
// SAFETY: the conditions of `MutexGuard::new` were satisfied when the original guard
616616
// was created, and have been upheld throughout `map` and/or `try_map`.
617617
// The signature of the closure guarantees that it will not "leak" the lifetime of the reference
618618
// passed to it. If the closure panics, the guard will be dropped.
@@ -720,7 +720,7 @@ impl<'a, T: ?Sized> MappedMutexGuard<'a, T> {
720720
F: FnOnce(&mut T) -> &mut U,
721721
U: ?Sized,
722722
{
723-
// SAFETY: the conditions of `MutedGuard::new` were satisfied when the original guard
723+
// SAFETY: the conditions of `MutexGuard::new` were satisfied when the original guard
724724
// was created, and have been upheld throughout `map` and/or `try_map`.
725725
// The signature of the closure guarantees that it will not "leak" the lifetime of the reference
726726
// passed to it. If the closure panics, the guard will be dropped.
@@ -751,7 +751,7 @@ impl<'a, T: ?Sized> MappedMutexGuard<'a, T> {
751751
F: FnOnce(&mut T) -> Option<&mut U>,
752752
U: ?Sized,
753753
{
754-
// SAFETY: the conditions of `MutedGuard::new` were satisfied when the original guard
754+
// SAFETY: the conditions of `MutexGuard::new` were satisfied when the original guard
755755
// was created, and have been upheld throughout `map` and/or `try_map`.
756756
// The signature of the closure guarantees that it will not "leak" the lifetime of the reference
757757
// passed to it. If the closure panics, the guard will be dropped.

0 commit comments

Comments
 (0)