mirror of
https://github.com/fluencelabs/interface-types
synced 2024-12-04 15:20:20 +00:00
fix(interface-types) Use lazy evaluation in the deserializer.
This commit is contained in:
parent
b9f54fb5c4
commit
099bf70712
@ -234,7 +234,7 @@ impl<'de, 'a> de::Deserializer<'de> for &'a mut Deserializer<'de> {
|
||||
{
|
||||
// Both `InterfaceValue::S32` and `InterfaceValue::I32`
|
||||
// represent `i32`.
|
||||
visitor.visit_i32(self.next_s32().or(self.next_i32())?)
|
||||
visitor.visit_i32(self.next_s32().or_else(|_| self.next_i32())?)
|
||||
}
|
||||
|
||||
fn deserialize_i64<V>(self, visitor: V) -> Result<V::Value, Self::Error>
|
||||
|
Loading…
Reference in New Issue
Block a user