Skip to content

Report diagnostic for field and value in property accessors when used as primary expressions only#74164

Merged
cston merged 2 commits intodotnet:mainfrom
cston:keywords-primary-expr-only
Jun 27, 2024
Merged

Report diagnostic for field and value in property accessors when used as primary expressions only#74164
cston merged 2 commits intodotnet:mainfrom
cston:keywords-primary-expr-only

Conversation

@cston
Copy link
Contributor

@cston cston commented Jun 26, 2024

Report a diagnostic for field and value in contexts where the identifiers will be treated as keywords in a later language version and where the meaning will change as a result.

This modifies the earlier change from #73570 to only report a diagnostic when the identifier is a primary expression, since it is assumed the parser will only treat field and value as keywords in those cases.

@cston cston requested a review from a team as a code owner June 26, 2024 05:07
@ghost ghost added Area-Compilers untriaged Issues and PRs which have not yet been triaged by a lead labels Jun 26, 2024
@cston cston force-pushed the keywords-primary-expr-only branch from 36d1f89 to ce4478c Compare June 26, 2024 05:11
@cston cston changed the title Parse field and value as keywords in primary expressions only Report diagnostic for field and value in property accessors when used as primary expressions only Jun 26, 2024
@cston cston requested review from a team and RikkiGibson June 27, 2024 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-Compilers Feature - Field Keyword untriaged Issues and PRs which have not yet been triaged by a lead

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants