Why is this enum declaration working now?

前端 未结 3 613
渐次进展
渐次进展 2020-12-21 01:50

While answering another question, Jon Skeet mentioned that there is a weird thing going on with the definition of enums. His answer.

He states that redi

3条回答
  •  暖寄归人
    2020-12-21 02:29

    This was an intentional language change in C# 6, whose specs have only been published in draft form. It was such a small change that we keep forgetting to put it into the specs.

    See also https://github.com/dotnet/roslyn/issues/623

提交回复
热议问题