From b604ea3e9389534950737ef6540d674a1e48e0d9 Mon Sep 17 00:00:00 2001 From: Stephen Chung Date: Thu, 6 Aug 2020 22:47:10 +0800 Subject: [PATCH] Fix serde doc test. --- src/serde/ser.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/serde/ser.rs b/src/serde/ser.rs index e13e22ec..f1a2ab77 100644 --- a/src/serde/ser.rs +++ b/src/serde/ser.rs @@ -85,9 +85,9 @@ impl DynamicSerializer { /// assert!(value.is::()); /// /// let map = value.cast::(); -/// let point = map.get("d").unwrap().downcast_ref::().unwrap(); -/// assert_eq!(*point.get("x").unwrap().downcast_ref::().unwrap(), 123.456); -/// assert_eq!(*point.get("y").unwrap().downcast_ref::().unwrap(), 999.0); +/// let point = map["d"].read_lock::().unwrap(); +/// assert_eq!(*point["x"].read_lock::().unwrap(), 123.456); +/// assert_eq!(*point["y"].read_lock::().unwrap(), 999.0); /// # } /// # Ok(()) /// # }