Skip to content
Discussion options

You must be logged in to vote

Hi, thanks for your question!

The problem of returning EOF for variant parsing is complicated because it is an ambiguous failure condition. #217 (comment) describes the situation as it applies to data enums with pre_assert, and similar issues exist here since magic is allowed to have heterogenous types which means maybe the author wants EOF when any magic EOF, or maybe the author wants EOF when the shortest magic EOF. Your idea of hinting the desired size is on the right track in this regard, but whatever solution should probably be consistent across all enum parsing, so needs to consider the situation from #217 too.

It does seem undesirable to me that we are returning NoVariantMatch when a…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by plaflamme
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants