about summary refs log tree commit diff
path: root/library/std/src
diff options
context:
space:
mode:
authorLinkTed <LinkTed@users.noreply.github.com>2020-09-18 14:08:31 +0200
committerLinkTed <LinkTed@users.noreply.github.com>2020-10-10 15:19:12 +0200
commitcc085e917078ebd5ff4c7c784d8cb04da85143c7 (patch)
tree05fa8decff6ff7d5ad88689d5b66ed243d424db4 /library/std/src
parente61148f98a21231d5bb3dea0140e3ff2f4d946e2 (diff)
downloadrust-cc085e917078ebd5ff4c7c784d8cb04da85143c7.tar.gz
rust-cc085e917078ebd5ff4c7c784d8cb04da85143c7.zip
Replace `assert` with `unreachable`
Diffstat (limited to 'library/std/src')
-rw-r--r--library/std/src/sys/unix/ext/net/tests.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/library/std/src/sys/unix/ext/net/tests.rs b/library/std/src/sys/unix/ext/net/tests.rs
index 16915a4cc1e..6cb2e729143 100644
--- a/library/std/src/sys/unix/ext/net/tests.rs
+++ b/library/std/src/sys/unix/ext/net/tests.rs
@@ -487,7 +487,7 @@ fn test_send_vectored_fds_unix_stream() {
             libc::close(fd_vec[0]);
         }
     } else {
-        assert!(false);
+        unreachable!("must be ScmRights");
     }
 }
 
@@ -553,7 +553,7 @@ fn test_send_vectored_with_ancillary_to_unix_datagram() {
         assert_eq!(cred1.get_uid(), cred_vec[0].get_uid());
         assert_eq!(cred1.get_gid(), cred_vec[0].get_gid());
     } else {
-        assert!(false);
+        unreachable!("must be ScmCredentials");
     }
 }
 
@@ -598,6 +598,6 @@ fn test_send_vectored_with_ancillary_unix_datagram() {
             libc::close(fd_vec[0]);
         }
     } else {
-        assert!(false);
+        unreachable!("must be ScmRights");
     }
 }