Пример #1
0
        public static MethodReference?TryImportEventRemove <TResult>(this ITypeSystem typeSystem, Expression <Func <TResult> > expression)
        {
            GetMemberInfo(expression, out var declaringType, out var name);

            return(typeSystem.TryImportEventRemove(declaringType, name));
        }
Пример #2
0
 public static MethodReference ImportEventRemove(this ITypeSystem typeSystem, Type declaringType, string name)
 {
     return(typeSystem.TryImportEventRemove(declaringType, name) ?? throw new WeavingException($"Can't find remove for event {name} on type {declaringType}"));
 }
Пример #3
0
 public static MethodReference?TryImportEventRemove <T>(this ITypeSystem typeSystem, string name)
 {
     return(typeSystem.TryImportEventRemove(typeof(T), name));
 }