4

I quickly go through Int32 struct definition, and I do not find any overload to operators like + - * /, but for String class, we can directly find them. How does Int32 implement such feature?

Bargitta
  • 2,266
  • 4
  • 22
  • 35

1 Answers1

3

They are baked into the CLR, and are not part of the code outputted as Reference Source. Hence you can't find them.

For String, only two operators are visible: those written in C#. Those in the CLR are also not shown (like the + operator).

Patrick Hofman
  • 153,850
  • 22
  • 249
  • 325