Skip to content

Fix deserializing adjacently tagged unit variants as sequences#3062

Draft
boomshroom wants to merge 1 commit intoserde-rs:masterfrom
boomshroom:patch-1
Draft

Fix deserializing adjacently tagged unit variants as sequences#3062
boomshroom wants to merge 1 commit intoserde-rs:masterfrom
boomshroom:patch-1

Conversation

@boomshroom
Copy link
Copy Markdown

This behavior is copied from the map visitor where this was already fixed.

Partially addresses #1762 and 3Hren/msgpack-rust#250. Resolving the struct variant part of the issue will be more tricky due to its codepath involving the untagged variants logic where the current behavior is more desirable.

This behavior is copied from the map visitor where this was already fixed.
@boomshroom
Copy link
Copy Markdown
Author

Seems this is more complex than I thought. The map version checks if the next field exists before handing over the variant to the seed, but the sequence version uses the variant before it gets the presence of a second field. If __Field implemented clone, then this would be easy.

@boomshroom boomshroom marked this pull request as draft April 15, 2026 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant