Reputation: 2546
I tried to see the implementation of [MethodImpl(MethodImplOptions.InternalCall)]
public extern int get_Length();
function, which in turn is Length property of string.
But reflector gave me the following error:
The member is not loaded or may be hidden due to your visibility settings
However the member is loaded and the visibility settings is ALL
Upvotes: 1
Views: 2825
Reputation: 106906
Certain very important types like String
have many methods that are implemented using native code. The Length
property of String
is one such example. This can also be seen from the extern
modifier. Reflector cannot show you the implementation of these methods.
Upvotes: 1
Reputation: 5122
I belive the extern methods are the ones that are "typically" implemented using other DLLs, mostly native ones. And of course, when that is the case you are out of the reflection turf!
Upvotes: 2