MethodDef LookupOverride(MethodOverride o) { MethodAndOverride info; if (!methodOverrides.TryGetValue(o.MethodDeclaration, out info)) return null; if (!comparer.Equals(info.MethodDeclaration.DeclaringType, o.MethodDeclaration.DeclaringType)) return null; return info.TargetMethod; }
void Load(MethodOverride obj) { Add(obj.MethodBody); Add(obj.MethodDeclaration); }
public MethodOverrideOptions(MethodOverride mo) { MethodBody = mo.MethodBody; MethodDeclaration = mo.MethodDeclaration; }
void Add(MethodOverride mo) { // It's a struct so can't be null Push(mo.MethodBody); Push(mo.MethodDeclaration); }
void InitializeFrom(MethodOverrideOptions options) { methodOverride = options.Create(); }