The fact is that the InterOp library is not actually written in C # and should not comply with C # rules. The only thing that should be is IL.
Visual Studio Metadata Viewer is struggling to show you metadata in your chosen language (in this case, C #), because it is usually much more readable than using IL code.
In some cases, this can be misleading (for example, ref parameters that should not really be ref in C #, default parameters before C # had default parameters, inconsistent values ββin default parameters ... ), but actually this is just a side effect of the fact that VS really does not know the language that was used to create the library, and even if that were the case, you would not want to see it - you are not indifferent to the interface open to you in C #, or something as close to him as possible.
Please note that these default parameters are really completely different from C # -C #, which are allowed during compilation on the client side (for example, changing the default parameters in library links does not change them in the user code until you recompile this code ), is not. As I said, VS does its best to get closer, but the CLR languages ββcan be very different.
source share