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
It would be really nice if we could write patterns like this:
[xs..., p(x), ys...]
This would match the first p(x) in the list. It's important here that matching is not greedy. Some ad-hoc support could be implement, but it gets quickly more challenging to cover all cases correctly. I believe we should compile the patterns into an automaton like regular expressions. The design of this would need to be worked out in some more detail.
Some quick thoughts:
P... would be like P* , and P should match the elements, not the entire list.
It would be nice to support more regular expression operators, but we'd have to get a bit creative with mapping those Julia syntax? I don't immediately see great use-cases for those.
The text was updated successfully, but these errors were encountered:
It would be really nice if we could write patterns like this:
[xs..., p(x), ys...]
This would match the first p(x) in the list. It's important here that matching is not greedy. Some ad-hoc support could be implement, but it gets quickly more challenging to cover all cases correctly. I believe we should compile the patterns into an automaton like regular expressions. The design of this would need to be worked out in some more detail.
Some quick thoughts:
The text was updated successfully, but these errors were encountered: