public int FindToken(IMethodDeclaration method) { object obj = methodTokens[method]; int num; if (obj != null) { num = (int)obj; } else { if (tokenField == null) { foreach (FieldInfo fieldInfo in method.GetType().GetFields(BindingFlags.Instance | BindingFlags.NonPublic)) { if (fieldInfo.FieldType == typeof(int)) { tokenField = fieldInfo; break; } } } num = (int)tokenField.GetValue(method); methodTokens.Add(method, num); } return(num); }