Last active
November 4, 2022 18:30
-
-
Save sunshowers/63fda4f8aaaba66dda39e7703e81b405 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[inline] | |
fn visit_map<__A>( | |
self, | |
mut __map: __A, | |
) -> _serde::__private::Result<Self::Value, __A::Error> | |
where | |
__A: _serde::de::MapAccess<'de>, | |
{ | |
let mut __collect = _serde::__private::Vec::< | |
_serde::__private::Option<( | |
_serde::__private::de::Content, | |
_serde::__private::de::Content, | |
)>, | |
>::new(); | |
while let _serde::__private::Some(__key) = | |
match _serde::de::MapAccess::next_key::<__Field>(&mut __map) { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
} | |
{ | |
match __key { | |
__Field::__other(__name) => { | |
__collect.push(_serde::__private::Some(( | |
__name, | |
match _serde::de::MapAccess::next_value(&mut __map) { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
}, | |
))); | |
} | |
} | |
} | |
let __field0: SubPackage = match _serde::de::Deserialize::deserialize( | |
_serde::__private::de::FlatMapDeserializer( | |
&mut __collect, | |
_serde::__private::PhantomData, | |
), | |
) { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
}; | |
_serde::__private::Ok(Package { sub: __field0 }) | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[inline] | |
fn visit_map<__A>( | |
self, | |
mut __map: __A, | |
) -> _serde::__private::Result<Self::Value, __A::Error> | |
where | |
__A: _serde::de::MapAccess<'de>, | |
{ | |
let mut __field0: _serde::__private::Option<String> = | |
_serde::__private::None; | |
let mut __field1: _serde::__private::Option<Map<String, Dependency>> = | |
_serde::__private::None; | |
while let _serde::__private::Some(__key) = | |
match _serde::de::MapAccess::next_key::<__Field>(&mut __map) { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
} | |
{ | |
match __key { | |
__Field::__field0 => { | |
if _serde::__private::Option::is_some(&__field0) { | |
return _serde::__private::Err( | |
<__A::Error as _serde::de::Error>::duplicate_field( | |
"name", | |
), | |
); | |
} | |
__field0 = _serde::__private::Some( | |
match _serde::de::MapAccess::next_value::<String>( | |
&mut __map, | |
) { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
}, | |
); | |
} | |
__Field::__field1 => { | |
if _serde::__private::Option::is_some(&__field1) { | |
return _serde::__private::Err( | |
<__A::Error as _serde::de::Error>::duplicate_field( | |
"dependencies", | |
), | |
); | |
} | |
__field1 = _serde::__private::Some( | |
match _serde::de::MapAccess::next_value::< | |
Map<String, Dependency>, | |
>(&mut __map) | |
{ | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
}, | |
); | |
} | |
_ => { | |
let _ = match _serde::de::MapAccess::next_value::< | |
_serde::de::IgnoredAny, | |
>(&mut __map) | |
{ | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
}; | |
} | |
} | |
} | |
let __field0 = match __field0 { | |
_serde::__private::Some(__field0) => __field0, | |
_serde::__private::None => { | |
match _serde::__private::de::missing_field("name") { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
} | |
} | |
}; | |
let __field1 = match __field1 { | |
_serde::__private::Some(__field1) => __field1, | |
_serde::__private::None => { | |
match _serde::__private::de::missing_field("dependencies") { | |
_serde::__private::Ok(__val) => __val, | |
_serde::__private::Err(__err) => { | |
return _serde::__private::Err(__err); | |
} | |
} | |
} | |
}; | |
_serde::__private::Ok(SubPackage { | |
name: __field0, | |
dependencies: __field1, | |
}) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment