about summary refs log tree commit diff
path: root/src/liballoc/tests
diff options
context:
space:
mode:
authorMazdak Farrokhzad <twingoow@gmail.com>2020-03-24 21:32:36 +0100
committerGitHub <noreply@github.com>2020-03-24 21:32:36 +0100
commitdb2c70bf4e9efcb53adcb8ed9c5b7eae8a55f33d (patch)
treeefe756070f1f4e129f4f8b74d1dd5728376fd516 /src/liballoc/tests
parentdc2901629960136330e86c02a0889f41481b4b00 (diff)
parent42b10e51c18ad37f671dc289aa0f183d4dbceab9 (diff)
downloadrust-db2c70bf4e9efcb53adcb8ed9c5b7eae8a55f33d.tar.gz
rust-db2c70bf4e9efcb53adcb8ed9c5b7eae8a55f33d.zip
Rollup merge of #70359 - kornelski:mustsplit, r=Dylan-DPC
must_use on split_off

A couple more for #70194
Diffstat (limited to 'src/liballoc/tests')
-rw-r--r--src/liballoc/tests/string.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/liballoc/tests/string.rs b/src/liballoc/tests/string.rs
index 08859b2b24b..d2f09eb4a75 100644
--- a/src/liballoc/tests/string.rs
+++ b/src/liballoc/tests/string.rs
@@ -266,14 +266,14 @@ fn test_split_off_empty() {
 fn test_split_off_past_end() {
     let orig = "Hello, world!";
     let mut split = String::from(orig);
-    split.split_off(orig.len() + 1);
+    let _ = split.split_off(orig.len() + 1);
 }
 
 #[test]
 #[should_panic]
 fn test_split_off_mid_char() {
     let mut orig = String::from("山");
-    orig.split_off(1);
+    let _ = orig.split_off(1);
 }
 
 #[test]