From 46ab9eb436ecf1a1f4bd5a5e6088e75fd5f7e261 Mon Sep 17 00:00:00 2001 From: Michael Gehring Date: Wed, 9 Jul 2014 15:35:54 +0200 Subject: ToStr::to_str -> ToString::to_string --- src/test/valid.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/test') diff --git a/src/test/valid.rs b/src/test/valid.rs index bc46d1a..9a812d5 100644 --- a/src/test/valid.rs +++ b/src/test/valid.rs @@ -15,7 +15,7 @@ fn to_json(toml: Value) -> json::Json { } match toml { String(s) => doit("string", json::String(s)), - Integer(i) => doit("integer", json::String(i.to_str())), + Integer(i) => doit("integer", json::String(i.to_string())), Float(f) => doit("float", json::String({ let (bytes, _) = strconv::float_to_str_bytes_common(f, 10, true, @@ -26,7 +26,7 @@ fn to_json(toml: Value) -> json::Json { let s = String::from_utf8(bytes).unwrap(); if s.as_slice().contains(".") {s} else {format!("{}.0", s)} })), - Boolean(b) => doit("bool", json::String(b.to_str())), + Boolean(b) => doit("bool", json::String(b.to_string())), Datetime(s) => doit("datetime", json::String(s)), Array(arr) => { let is_table = match arr.as_slice().head() { -- cgit v1.2.3