From fa8dff887f4f8d85a528924cb429012df552b471 Mon Sep 17 00:00:00 2001 From: kudzu_cp <6d05c8c8ef5431987001abfdb2eadc9593ac9498> Date: Sun, 13 Sep 2009 14:02:59 +0000 Subject: [PATCH] --- source2/IL2PCU/Cosmos.IL2CPU/ILScanner.cs | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/source2/IL2PCU/Cosmos.IL2CPU/ILScanner.cs b/source2/IL2PCU/Cosmos.IL2CPU/ILScanner.cs index 94b8220be..be6af812c 100644 --- a/source2/IL2PCU/Cosmos.IL2CPU/ILScanner.cs +++ b/source2/IL2PCU/Cosmos.IL2CPU/ILScanner.cs @@ -333,8 +333,17 @@ namespace Cosmos.IL2CPU { var xParams = aMethod.GetParameters(); var xParamTypes = new Type[xParams.Length]; for (int i = 0; i < xParams.Length; i++) { + Queue(xParamTypes[i], aMethod, "Parameter"); xParamTypes[i] = xParams[i].ParameterType; } + // Queue Types directly related to method + if (!aIsPlug) { + // Don't queue declaring types of plugs + Queue(aMethod.DeclaringType, aMethod, "Declaring Type"); + } + if (aMethod is System.Reflection.MethodInfo) { + Queue(((System.Reflection.MethodInfo)aMethod).ReturnType, aMethod, "Return Type"); + } // We only need to look in ancestors and descendants if the method is virtual if (aMethod.IsVirtual) { @@ -408,18 +417,6 @@ namespace Cosmos.IL2CPU { } } } - - // Queue Types directly related to method - if (!aIsPlug) { - // Don't queue declaring types of plugs - Queue(aMethod.DeclaringType, aMethod, "Declaring Type"); - } - if (aMethod is System.Reflection.MethodInfo) { - Queue(((System.Reflection.MethodInfo)aMethod).ReturnType, aMethod, "Return Type"); - } - foreach (var xType in xParamTypes) { - Queue(xType, aMethod, "Parameter"); - } } }