예제 #1
0
		public void VisitMethod(MethodDefinition method)
		{				
			if (method.ExternallyVisible(Cache))
			{
				Log.DebugLine(this, "-----------------------------------"); 
				Log.DebugLine(this, "checking {0}", method.Name);				

				if (DoObsoleteTerm(method.Name))
				{
					Reporter.MethodFailed(method, CheckID, 0, string.Empty);
				}
				else
				{
					foreach (ParameterDefinition arg in method.Parameters)
					{
						Log.DebugLine(this, "checking {0}", arg.Name);				
						if (DoObsoleteTerm(arg.Name))
						{
							Reporter.MethodFailed(method, CheckID, 0, string.Empty);
							break;
						}
					}
				}
			}
		}
예제 #2
0
		public void VisitMethod(MethodDefinition method)
		{
			Log.DebugLine(this, "{0}", method);
			Log.DebugLine(this, "   IsPInvokeImpl: {0}", method.IsPInvokeImpl);
			Log.DebugLine(this, "   IsUnmanagedExport: {0}", method.IsUnmanagedExport);
			
			if (method.IsPInvokeImpl)
			{
				if (method.ExternallyVisible(Cache))
				{
					Reporter.MethodFailed(method, CheckID, 0, string.Empty);
				}
			}
		}
예제 #3
0
		public void VisitMethod(MethodDefinition method)
		{						
			if (method.ExternallyVisible(Cache))
			{
				m_methods.Add(method.Name);
				
				List<string> args = new List<string>();
				foreach (ParameterDefinition p in method.Parameters)
					args.Add(p.Name);
	
				List<string> bad = new List<string>();
				DoGetMatches(bad, args, "Arguments: ");
	
				if (bad.Count == 1)
				{
					Log.DebugLine(this, bad[0]);
					Reporter.MethodFailed(method, CheckID, 0, bad[0]);
				}
			}
		}