mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-10-21 19:26:17 +00:00
Fix deserializing a tuple from a sequence
This commit is contained in:
1 parent
9d1f777282
commit
dce88b74da
1 file changed
+2
-1
@@ -305,7 +305,8 @@ pub trait Deserializer<E>: Iterator<Result<Token, E>> {
|
||||
fn expect_tuple_start(&mut self, token: Token) -> Result<uint, E> {
|
||||
match token {
|
||||
TupleStart(len) => Ok(len),
|
||||
token => Err(self.syntax_error(token, [TupleStartKind])),
|
||||
SeqStart(len) => Ok(len),
|
||||
token => Err(self.syntax_error(token, [TupleStartKind, SeqStartKind])),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user