Parse CIL code with Regex
问题 I have a *.il file. I want to find all non-empty methods in it (.method). For example: .class private auto ansi beforefieldinit MyApp.Program extends [mscorlib]System.Object { //catch its body .method private hidebysig static void Main(string[] args) cil managed { .entrypoint // .maxstack 8 IL_0000: nop IL_0001: ret } //catch its body .method public hidebysig specialname rtspecialname instance void .ctor() cil managed { // .maxstack 8 IL_0000: ldarg.0 IL_0001: call instance void [mscorlib