1

I have recently installed visual studio 2015 (previously on 2012), and when I use an Enum (instantiated or otherwise) in either VB.NET or C#, as well as the Enum members I also have the option of value__, an Integer.

What does this option do?

enter image description here

--Edit-- In this question here, it says that

" I found that value__ is just a special instance field used by the enum to hold the value of the selected member"

Could you explain what that means in practice? In my second example above, what would "value__" tell me for test? would it just be the underlying number for the enum value? Why is this now accessible in VS2015? Is that true for me or for everyone?

Community
  • 1
  • 1
simonalexander2005
  • 4,338
  • 4
  • 48
  • 92

1 Answers1

0

It stores the enumeration value for the compiler to use (see What is the purpose of the public "value__" field that I can see in Reflector against my enum?) - the fact that it is visible in VS is probably a bug - it disappears in later releases.

simonalexander2005
  • 4,338
  • 4
  • 48
  • 92