Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tuple patterns in parameter declarations #191

Merged
merged 1 commit into from
Nov 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions rzk/src/Language/Rzk/Free/Syntax.hs
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,7 @@ unsafeTermToPattern = ttp
Rzk.Unit loc -> Rzk.PatternUnit loc
Rzk.Var loc x -> Rzk.PatternVar loc x
Rzk.Pair loc l r -> Rzk.PatternPair loc (ttp l) (ttp r)
Rzk.Tuple loc t1 t2 ts -> Rzk.PatternTuple loc (ttp t1) (ttp t2) (map ttp ts)
term -> error ("ERROR: expected a pattern but got\n " ++ Rzk.printTree term)

fromTerm' :: Term' -> Rzk.Term
Expand Down
Loading