Describe the issue or suggestion
Identifier names - rules and conventions page specifies that:
- Use PascalCase for constant names, both fields and local constants.
- Private instance fields start with an underscore (_) and the remaining text is camelCased.
And the .NET Runtime team's coding style also specifies that:
We use _camelCase for internal and private fields
We use PascalCasing to name all our constant local variables and fields.
But it doesn't clarify whether private constants should be _camelCase or PascalCase.
The const keyword page implies that it should always be PascalCase. But it also illustrates some odd naming conventions, such as public fields called x and y (shouldn't it be X and Y?).
I think an explicit clarification would be helpful here.
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
Associated WorkItem - 595626
Describe the issue or suggestion
Identifier names - rules and conventions page specifies that:
And the .NET Runtime team's coding style also specifies that:
But it doesn't clarify whether private constants should be
_camelCaseorPascalCase.The const keyword page implies that it should always be
PascalCase. But it also illustrates some odd naming conventions, such as public fields calledxandy(shouldn't it beXandY?).I think an explicit clarification would be helpful here.
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
Associated WorkItem - 595626