mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-06-14 03:31:02 +00:00
Have visit_enum_simple default to calling visit_tuple_variant
This commit is contained in:
@@ -131,7 +131,14 @@ pub trait Serializer {
|
||||
variant_index: usize,
|
||||
variant: &'static str,
|
||||
value: T) -> Result<(), Self::Error>
|
||||
where T: Serialize;
|
||||
where T: Serialize,
|
||||
{
|
||||
self.visit_tuple_variant(
|
||||
name,
|
||||
variant_index,
|
||||
variant,
|
||||
Some(value))
|
||||
}
|
||||
|
||||
fn visit_none(&mut self) -> Result<(), Self::Error>;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user