You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The basis for this was laid in #49, which added a function called verify_shape to verify the shapes of lists.
As of now, verify_shapes is capable of recursively checking the lengths and element types of lists, and is used by gen_set_expr to check the syntax of a set expression.
Such a pattern matching framework calls for a discussion before further development.
We can probably take inspiration from Python's own match statement for pattern matching. The only reason it may not be feasible for our use is that we will have to write match-case statements everywhere, which can get messy unlike one-liner function calls.
The text was updated successfully, but these errors were encountered:
The basis for this was laid in #49, which added a function called
verify_shape
to verify the shapes of lists.As of now,
verify_shapes
is capable of recursively checking the lengths and element types of lists, and is used bygen_set_expr
to check the syntax of aset
expression.Such a pattern matching framework calls for a discussion before further development.
We can probably take inspiration from Python's own
match
statement for pattern matching. The only reason it may not be feasible for our use is that we will have to writematch-case
statements everywhere, which can get messy unlike one-liner function calls.The text was updated successfully, but these errors were encountered: