From 811d89a01b241c695f4a4f280fc0c959fb2712dc Mon Sep 17 00:00:00 2001 From: llogiq Date: Fri, 14 Aug 2015 14:26:57 +0200 Subject: [PATCH] removed String::from_str(..) to fix build with 1.4.0-nightly/2015-08-14 --- tests/compile-fail/cmp_owned.rs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/tests/compile-fail/cmp_owned.rs b/tests/compile-fail/cmp_owned.rs index 5951dc1bbd7..2765da5cf23 100755 --- a/tests/compile-fail/cmp_owned.rs +++ b/tests/compile-fail/cmp_owned.rs @@ -1,4 +1,4 @@ -#![feature(plugin, collections)] +#![feature(plugin)] #![plugin(clippy)] #[deny(cmp_owned)] @@ -13,11 +13,8 @@ fn main() { x != "foo".to_owned(); //~ERROR this creates an owned instance - #[allow(deprecated)] // for from_str - fn old_timey(x : &str) { - x != String::from_str("foo"); //~ERROR this creates an owned instance - } - old_timey(x); + // removed String::from_str(..), as it has finally been removed in 1.4.0 + // as of 2015-08-14 x != String::from("foo"); //~ERROR this creates an owned instance }