public static bool AnyFlag(this Enum baseEnum, Enum value) { if (!Type.GetTypeHandle(baseEnum).Equals(Type.GetTypeHandle(value))) { throw ExceptionHelper.EnumTypeDoesNotMatch("value", value.GetType(), baseEnum.GetType()); } return((ToUInt64(baseEnum) & ToUInt64(value)) != 0); }
public static bool AnyFlag(this Enum baseEnum, Enum value) { if (!baseEnum.GetType().IsEquivalentTo(value.GetType())) { throw ExceptionHelper.EnumTypeDoesNotMatch(value.GetType(), baseEnum.GetType()); } return((ToUInt64(baseEnum) & ToUInt64(value)) != 0); }