diff --git a/src/value/tagged.rs b/src/value/tagged.rs index 614981f1..9f0d8aa5 100644 --- a/src/value/tagged.rs +++ b/src/value/tagged.rs @@ -41,16 +41,6 @@ pub struct TaggedValue { pub value: Value, } -impl TaggedValue { - /// Creates a new `TaggedValue`. - pub fn copy(&self) -> TaggedValue { - TaggedValue { - tag: self.tag.clone(), - value: self.value.clone(), - } - } -} - impl Tag { /// Creates a new `Tag`. pub fn new(string: impl Into) -> Self { diff --git a/tests/test_tagged.rs b/tests/test_tagged.rs index d43f481f..016f86e1 100644 --- a/tests/test_tagged.rs +++ b/tests/test_tagged.rs @@ -1,9 +1,6 @@ #[cfg(test)] mod tests { - use serde_yml::{ - value::{tagged::nobang, Tag, TaggedValue}, - Value, - }; + use serde_yml::value::{tagged::nobang, Tag}; /// Test for creating a new Tag. #[test] @@ -19,16 +16,6 @@ mod tests { assert_eq!(tag.string, "foo"); } - /// Test for copying a TaggedValue. - #[test] - fn test_tagged_value_copy() { - let tag = Tag::new("foo"); - let value = Value::String("bar".to_owned()); - let tagged_value = TaggedValue { tag, value }; - let copied = tagged_value.copy(); - assert_eq!(tagged_value, copied); - } - /// Test for removing '!' from a string. #[test] fn test_nobang_with_bang() {