Nondeterministic automaton

we're working on this nondeterministic automaton in a serde::de::Deserialize and we'd like some help with it. this is what we have so far: blob

we're struggling with figure out how to decide what type to deserialize and how to handle the different validators. this nondeterministic automaton thing we're doing is loosely based on what we learned from the following article a few years ago: Regular Expression Matching Can Be Simple And Fast

how can we continue this?

Could you please be a bit more elaborate about your question? I could not understand it.

so we have these "value subtrees" and we're not sure how to decide which type to ask for (deserializer.deserialize_*) when there are multiple subtrees going on. if that makes sense?