-
Notifications
You must be signed in to change notification settings - Fork 4
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
Generalize matching #78
base: master
Are you sure you want to change the base?
Conversation
…ng rule not to fire
@@ -120,4 +121,19 @@ module TEST-MATCH-ASSOC | |||
) | |||
) | |||
.Declarations | |||
// Match multiple occurances of a variable | |||
rule test("match-assoc", 10) | |||
=> symbol c ( Data ) : Data |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How does this work? I thought that #matchAssoc
, which is a function, is evaluated before the symbol declaration.
@@ -140,12 +140,15 @@ only in this scenario*. | |||
```k | |||
syntax Variable ::= VariableName "{" Sort "}" [klabel(sortedVariable)] | |||
syntax SetVariable ::= SharpName [klabel(setVariable)] | |||
syntax Context ::= VariableName "[" Pattern "]" [klabel(context)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this represent? I thought a context is a pattern with a 'hole', which is a variable. So, does VariableName
design the variable which plays the role of hole in the Pattern
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, please explain the meaning of VariableName here.
No description provided.