about summary refs log tree commit diff
path: root/src/liballoc/tests/string.rs
diff options
context:
space:
mode:
authorPhilipp Hansch <dev@phansch.net>2019-04-20 16:05:25 +0200
committerPhilipp Hansch <dev@phansch.net>2019-04-20 16:05:25 +0200
commit110a73d6c60eab76ce39426eb29cd1d016f6539c (patch)
tree2ccdf6323d640d4203e52cf942369da6d89da38b /src/liballoc/tests/string.rs
parentd5d1ee86bb72730a77abfcab3a38c1a5d1b757bf (diff)
downloadrust-110a73d6c60eab76ce39426eb29cd1d016f6539c.tar.gz
rust-110a73d6c60eab76ce39426eb29cd1d016f6539c.zip
Deny rust_2018_idioms in liballoc tests
Diffstat (limited to 'src/liballoc/tests/string.rs')
-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 7e75b8c4f28..765210e5aa6 100644
--- a/src/liballoc/tests/string.rs
+++ b/src/liballoc/tests/string.rs
@@ -54,11 +54,11 @@ fn test_from_utf8() {
 #[test]
 fn test_from_utf8_lossy() {
     let xs = b"hello";
-    let ys: Cow<str> = "hello".into_cow();
+    let ys: Cow<'_, str> = "hello".into_cow();
     assert_eq!(String::from_utf8_lossy(xs), ys);
 
     let xs = "ศไทย中华Việt Nam".as_bytes();
-    let ys: Cow<str> = "ศไทย中华Việt Nam".into_cow();
+    let ys: Cow<'_, str> = "ศไทย中华Việt Nam".into_cow();
     assert_eq!(String::from_utf8_lossy(xs), ys);
 
     let xs = b"Hello\xC2 There\xFF Goodbye";