typst-community / valkyrie

Type safe type safety for Typst
Other
25 stars 2 forks source link

Tuples do not respect optional elements #34

Open m-haug opened 3 weeks ago

m-haug commented 3 weeks ago

I'm trying to parse a schema with an optional trailing content using tuple. However, when I use a schema like

tuple(string(), string(), content(optional: true))

valkyrie panics when trying to access the third element of the tuple if the trailing content is not specified.

JamesxX commented 3 weeks ago

Fixed in next version (see #31 )