private AnalysisNet.IInstruction ProcessStoreArrayElement(Cecil.Cil.Instruction op) { AnalysisNet.Types.ArrayType arrayType = null; switch (op.OpCode.Code) { //case Mono.Cecil.Cil.Code.Array_Set: // arrayType = typeExtractor.ExtractType(op.Operand as Cecil.TypeReference) as ArrayType; // break; //case Mono.Cecil.Cil.Code.Stelem: case Mono.Cecil.Cil.Code.Stelem_Any: AnalysisNet.Types.IType extractedType = typeExtractor.ExtractType(op.Operand as Cecil.TypeReference); arrayType = new AnalysisNet.Types.ArrayType(extractedType); break; default: arrayType = new AnalysisNet.Types.ArrayType(OperationHelper.GetOperationType(op.OpCode.Code)); break; } if (arrayType == null) { throw new NotImplementedException(); } AnalysisNetBytecode.StoreArrayElementInstruction instruction = new AnalysisNetBytecode.StoreArrayElementInstruction((uint)op.Offset, arrayType); return(instruction); }
private AnalysisNet.IInstruction ProcessStoreArrayElement(Cecil.Cil.Instruction op, AnalysisNet.Types.ArrayType arrayType) { AnalysisNetBytecode.StoreArrayElementInstruction instruction = new AnalysisNetBytecode.StoreArrayElementInstruction((uint)op.Offset, arrayType); return(instruction); }