How to find sources of .Net external external method
I'm looking at HasFlag , there is a call InternalHasFlag(...)
. How can I see its sources?
The question may be a bit misleading (feel free to fix it).
My original problem comes from trying to make an extension method enum
, here is one
public static Enum Mask(this Enum @this, Enum mask)
{
if (mask == null)
throw new ArgumentNullException("mask");
if (!@this.GetType().IsEquivalentTo(mask.GetType()))
throw new ArgumentException("Type mismatch", "mask");
return (Enum)(object)((int)(object)@this & (int)(object)mask);
}
I'm very unsure about the last line and wanted to see how ms-guy does it.
+3
source to share
No one has answered this question yet
See similar questions:
or similar: