From 7c61be9c90aef91e038564bd05eb7354da18fb5c Mon Sep 17 00:00:00 2001 From: Sebastian Hahn Date: Sat, 30 Jul 2016 07:31:38 +0200 Subject: [PATCH] Rename is_{string,boolean} to is_{str,bool} This matches the rename of as_{string,boolean} to as_{str,bool}. Fixes issue #126 --- json/src/value.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/json/src/value.rs b/json/src/value.rs index adb616f63..56d66fcbb 100644 --- a/json/src/value.rs +++ b/json/src/value.rs @@ -262,7 +262,7 @@ impl Value { } /// Returns true if the `Value` is a String. Returns false otherwise. - pub fn is_string(&self) -> bool { + pub fn is_str(&self) -> bool { self.as_str().is_some() } @@ -339,7 +339,7 @@ impl Value { } /// Returns true if the `Value` is a Boolean. Returns false otherwise. - pub fn is_boolean(&self) -> bool { + pub fn is_bool(&self) -> bool { self.as_bool().is_some() }