Function to_lowercase

Source
pub(crate) fn to_lowercase(s: &str) -> Cow<'_, str>
Expand description

Returns the given &str if already lowercased to avoid allocation, otherwise lowercases it.