I know my mistakes. CLR just allows to set the call stack successively.When I want to use V_1, V_0 must be used. Here is question,
how can I know how many Call stack variable are used? and How to use the stloc.s, exactly how to write its parameter? 在 2016年3月8日星期二 UTC+8上午12:53:41,Jb Evain写道: > > Hi, > > Thanks for using Cecil and reaching out on the group, but please be > careful. You're sending multiple messages with basically the same > content, which is not a great way to get help. > > It's definitely possible to insert instructions that are manipulating the > stack. > > If you face any issue, please use peverify to diagnose what's wrong in the > IL. > > Short of that, please show some code in a Gist or in pastebin. > > Jb > > > On Mon, Mar 7, 2016 at 12:53 AM, <[email protected] <javascript:>> > wrote: > > As the title mentioned, when I modified a method, where there is no > variable > > defined original, I cannot insert new > > > > instructions to use the Call Stack, like stloc, etc. For example: > > > > the original program is like: > > > > void fun() > > { > > Console.WriteLine("hello."); > > } > > > > I cannot use Mono.Cecil to insert instruction, stloc_0 or ldloc_0, cause > > Call Stack loc_0 seems not able to use.and CLR reports error. > > > > How to deal with it? Thank you for your advice. > > > > -- > > -- > > -- > > mono-cecil > > --- > > You received this message because you are subscribed to the Google > Groups > > "mono-cecil" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to [email protected] <javascript:>. > > For more options, visit https://groups.google.com/d/optout. > -- -- -- mono-cecil --- You received this message because you are subscribed to the Google Groups "mono-cecil" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
