public virtual FieldInfo GetField(string name, BindingFlags bindingAttr) { RuntimeModule module = this as RuntimeModule; if (module == null) { throw new NotImplementedException(); } return(module.GetField(name, bindingAttr)); }
public virtual FieldInfo GetField(String name, BindingFlags bindingAttr) { // This API was made virtual in V4. Code compiled against V2 might use // "call" rather than "callvirt" to call it. // This makes sure those code still works. RuntimeModule rtModule = this as RuntimeModule; if (rtModule != null) { return(rtModule.GetField(name, bindingAttr)); } throw new NotImplementedException(); }