Mono.Cecil MethodDefinition变量不可见(Mono.Cecil MethodDefinition Variables not visible)
我遇到了一个奇怪的问题,当我尝试列出所选方法中的所有MethodDefinition.Body.Variables时,它似乎在完成循环之前跳过了几个。 我需要使用任何过滤器来查看所述方法中的所有变量吗?(所有这些都是局部变量)
MethodDefinition example = module.GetType("Example.Program").Methods.First(m => m.Name == "Main"); foreach (VariableDefinition def in example.Body.Variables) Console.WriteLine(def.VariableType.Name);I've encountered a strange issue, when I try to list all of the MethodDefinition.Body.Variables in a selected method it seems to skip over a few before completing the loop. Are there any filters I need to use in order to see all variables within said method?(All of them are local variables)
MethodDefinition example = module.GetType("Example.Program").Methods.First(m => m.Name == "Main"); foreach (VariableDefinition def in example.Body.Variables) Console.WriteLine(def.VariableType.Name);最满意答案
我已经解决了我的问题,这是我的错。(ILSpy设置,woops)
I've fixed my issue, it was a fault on my side.(ILSpy settings, woops)
更多推荐
发布评论