Esempio n. 1
0
 public VMInstruction Translate(VMBody body, MethodDef method, int index, Offsets helper, out bool success)
 {
     helper.Add(index, -1);
     success = true;
     return(new VMInstruction(VMOpCode.UNUSED));
 }
Esempio n. 2
0
 public byte[] Serialize(VMBody body, VMInstruction instruction, Offsets helper) =>
 Array.Empty <byte>();
Esempio n. 3
0
 public byte[] Serialize(VMBody body, VMInstruction instruction, Offsets helper)
 {
     return(new[] { (byte)VMOpCode.Add });
 }
Esempio n. 4
0
 public VMInstruction Translate(VMBody body, MethodDef method, int index, Offsets helper, out bool success)
 {
     success = true;
     return(new VMInstruction(VMOpCode.Pop));
 }
Esempio n. 5
0
 public VMInstruction Translate(VMBody body, MethodDef method, int index, Offsets helper, out bool success)
 {
     success = true;
     return(new VMInstruction(VMOpCode.Int32, (int)method.Body.Instructions[index].Operand));
 }
Esempio n. 6
0
 public VMInstruction Translate(VMBody body, MethodDef method, int index, Offsets helper, out bool success)
 {
     success = true;
     return(new VMInstruction(VMOpCode.Je, method.Body.Instructions.IndexOf(method.Body.Instructions[index])));
 }
Esempio n. 7
0
 public byte[] Serialize(VMBody body, VMInstruction instruction, Offsets helper) =>
 new[] { (byte)VMOpCode.Dup };