logo
pub fn btreemap_deserialize_v1_powerlevel_values<'de, D, T>(
    de: D
) -> Result<BTreeMap<T, Int>, D::Error> where
    D: Deserializer<'de>,
    T: Deserialize<'de> + Ord
Expand description

Take a BTreeMap with values of either an integer number or a string and deserialize those to integer numbers.

To be used like this: #[serde(deserialize_with = "btreemap_deserialize_v1_powerlevel_values")]