Add isDelegate() method
This commit is contained in:
parent
8b0bf54d62
commit
76241db427
|
@ -278,8 +278,12 @@ namespace de4dot.blocks {
|
|||
}
|
||||
}
|
||||
|
||||
public static bool isDelegate(TypeReference type) {
|
||||
return type != null && (type.FullName == "System.Delegate" || type.FullName == "System.MulticastDelegate");
|
||||
}
|
||||
|
||||
public static bool isDelegateType(TypeDefinition type) {
|
||||
return type != null && type.BaseType != null && type.BaseType.FullName == "System.MulticastDelegate";
|
||||
return type != null && isDelegate(type.BaseType);
|
||||
}
|
||||
|
||||
public static bool isSameAssembly(TypeReference type, string assembly) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user