Friday 15 May 2015

Can hand-written CIL do things that C# cannot? -


So this is a very simple question, but I do not see an answer anywhere about it.

If I somehow generate CIL code manually, is it possible to do something that can be restricted in C #? What kind of things (Obviously I am not completely expecting a list.)

I have not considered very good details of CIL, but considering that CLR is considered language-anonymity, then Even hard work is supported between written components in different languages, I expect CIL to work at the object-level and maybe its own type system. I can imagine that C #S There is a lesser type of strict system, and perhaps some other things that may differ but I was thinking that nobody knows without reading the entire language specification ...

Nothing that gives you C + But currently C programming in C # has not been created. Note that the upcoming C # 6 says some of them.

Definitely not the full list, on top of my head:

  • try .. fault blocks they only execute when < Try the code> end block exception.
  • Exception filter. VB is already with them and C # 6 will also have them: hold .. when .
  • The Stretch (Value Type) parameter will be near the Constructor C # 6. Edit: svick has commented that the feature was deleted.
  • The usual type of obstruction on enum
  • A protected and internal visibility modifier (you should be in the same class <

I'm sure there is more.


No comments:

Post a Comment