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

Define the variables that are in-scope when a property is expanded #13

Closed
xatapult opened this issue Jun 30, 2021 · 3 comments
Closed
Labels
2025 A change made in preparing the 2025 edition clarification Discusses and clarifies ambiguities diagnostics Issues relating to the diagnostics mechanism properties Issues relating to the properties mechanism

Comments

@xatapult
Copy link
Collaborator

In the specification it is not defined what variables are in-scope when a property is expanded. So what variables is a <value-of> in a property allowed to reference?

I would expect only the variables that are lexically in scope, meaning, for properties, only global variables defined before the property is defined? Or also the variables that are defined in the pattern/rule that fired and caused the property to be expanded?

@rjelliffe
Copy link
Member

rjelliffe commented Jun 30, 2021 via email

@dmj
Copy link
Member

dmj commented Jul 7, 2021

In this case, it would clearly be that the property is evaluated in the
context of the assert etc. and so the variables should be visible.

The same would be true of diagnostics.

I agree. Properties and diagnostics belong to the same "logical category", so to speak: They encode information relating to a failed assertion or successful report.

@dmj dmj added the clarification Discusses and clarifies ambiguities label Aug 30, 2021
@AndrewSales AndrewSales added diagnostics Issues relating to the diagnostics mechanism properties Issues relating to the properties mechanism labels Jun 19, 2023
@AndrewSales AndrewSales added the 2025 A change made in preparing the 2025 edition label Mar 3, 2024
@AndrewSales
Copy link
Collaborator

Clarified this in latest draft for both properties and diagnostics.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2025 A change made in preparing the 2025 edition clarification Discusses and clarifies ambiguities diagnostics Issues relating to the diagnostics mechanism properties Issues relating to the properties mechanism
Projects
None yet
Development

No branches or pull requests

4 participants