Skip to content

Match with symbols #2366

Answered by Kodiologist
jakesnell asked this question in Q&A
Dec 2, 2022 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

Python limits what is allowed as a pattern in a match statement, and Hy doesn't try to extend this. In particular, Hy won't try to expand macro calls in a pattern, and 'rock is just syntactic sugar for calling the macro quote. I don't know what your real situation is, but I bet you'd be happier with Hyrule's case or branch.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jakesnell
Comment options

Answer selected by jakesnell
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