1

In what way are each intended to be used? Also the differences between them?

For an example:

sbyte myByte = 1;
SByte myByte = 1;

1 Answers1

3

sbyte is an alias of System.SByte. There is no difference between the two. The guidelines state that it is recommended to use the alias sbyte instead of SByte. You can see the MSDN documentation here: https://msdn.microsoft.com/en-us/library/d86he86x.aspx

RobbieK
  • 115
  • 7
  • The difference is `sbyte` is a **keyword** in C#. It always has the same meaning. But `SByte` is an identifier like any else. It can resolve to any namespace, class (or other type), property, method, variable, etc. depending on context. By context I mean, what classes does the identifier occur inside, what is the namespace, what `using` directives are present at what namespace level, etc. (Of course I do not recommend using the identifier `SByte` for one's own types and members, but it is allowed.) – Jeppe Stig Nielsen Apr 06 '15 at 08:48