_populous_
_populous_
CC#
Created by _populous_ on 6/3/2024 in #help
✅ How can i turn this into a query?
Current code: foreach (var type in module.Types) { if (type.Name == "foo") { foreach (var method in type.Methods) { if (method.Name == "bar") MethodDefinition myMethod = method; } } } I am trying to turn this code into a query, so it's shorter and prettier.. but i can't seem to get it right.. MethodDefinition myMethod = from type module.Types where type.Name == "foo" ... I just get errors with whatever i try..
16 replies