diff --git a/libraries/cbor/src/macros.rs b/libraries/cbor/src/macros.rs index d8dc860..9cf4178 100644 --- a/libraries/cbor/src/macros.rs +++ b/libraries/cbor/src/macros.rs @@ -46,7 +46,7 @@ use core::iter::Peekable; /// read_cbor_map! { /// let { /// 1 => x, -/// 2 => y, +/// "key" => y, /// } = map; /// }; /// # } @@ -59,8 +59,9 @@ use core::iter::Peekable; /// # /// # fn main() { /// # let mut map = alloc::collections::BTreeMap::::new(); -/// let x: Option = map.remove(&cbor_unsigned!(1)); -/// let y: Option = map.remove(&cbor_unsigned!(2)); +/// use cbor::values::IntoCborKey; +/// let x: Option = map.remove(&1.into_cbor_key()); +/// let y: Option = map.remove(&"key".into_cbor_key()); /// # } /// ``` #[macro_export]