Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add better documentation for unsafe block
  • Loading branch information
Krishna Sai Veera Reddy committed Dec 10, 2019
commit 1f07aa582a41e6fc253139909d3bf9bfd04a9d6d
2 changes: 1 addition & 1 deletion src/libcore/cmp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1134,7 +1134,7 @@ mod impls {
-1 => Less,
0 => Equal,
1 => Greater,
// SAFETY: Unreachable code
// SAFETY: bool as i8 returns 0 or 1, so the difference can't be anything else
_ => unsafe { unreachable_unchecked() },
}
}
Expand Down