events: Fix non-public doc(hidden) fn

This commit is contained in:
Jonas Platte 2022-01-17 11:16:51 +01:00
parent e387abda81
commit 026c186b32
No known key found for this signature in database
GPG Key ID: 7D261D771D915378

View File

@ -407,12 +407,11 @@ where
#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)] #[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct PrivOwnedStr(Box<str>); pub struct PrivOwnedStr(Box<str>);
/// Helper function for erroring when trying to serialize an event enum _Custom /// Helper function for erroring when trying to serialize an event enum _Custom variant that can
/// variant that can only be created by deserializing from an unknown event /// only be created by deserializing from an unknown event type.
/// type.
#[doc(hidden)] #[doc(hidden)]
#[allow(clippy::ptr_arg)] #[allow(clippy::ptr_arg)]
fn serialize_custom_event_error<S: Serializer>(_: &String, _: S) -> Result<S::Ok, S::Error> { pub fn serialize_custom_event_error<S: Serializer>(_: &String, _: S) -> Result<S::Ok, S::Error> {
Err(serde::ser::Error::custom( Err(serde::ser::Error::custom(
"Failed to serialize event [content] enum: Unknown event type.\n\ "Failed to serialize event [content] enum: Unknown event type.\n\
To send custom events, turn them into `Raw<EnumType>` by going through To send custom events, turn them into `Raw<EnumType>` by going through