This is how you mark that you are in a certain context. For example, here
is a rough outline of some code that uses inContext to mark when you are
parsing a specific definition:
First we parse the function name, and then we parse the rest of the definition.
Importantly, we call inContext so that any dead end that occurs in
definitionBody will get this extra context information. That way you can say
things like, “I was expecting an equals sign in the view definition.” Context!
This is how you mark that you are in a certain context. For example, here is a rough outline of some code that uses
inContextto mark when you are parsing a specific definition:Example
First we parse the function name, and then we parse the rest of the definition. Importantly, we call
inContextso that any dead end that occurs indefinitionBodywill get this extra context information. That way you can say things like, “I was expecting an equals sign in theviewdefinition.” Context!