public override void SetAssingCode(ILGenerator codeGenerator, TypeBuilder typeBuilder, ModuleBuilder moduleBuilder, ExpressionNode assingExp)
 {
     Array.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
     AccessExp.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
     assingExp.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
     codeGenerator.Emit(OpCodes.Stelem, Environment.GetCLRType(assingExp.ReturnType));
 }
        public override void SetAssingCode(ILGenerator codeGenerator, TypeBuilder typeBuilder, ModuleBuilder moduleBuilder, ExpressionNode assingExp)
        {
            RecordType recType = (RecordType)Record.ReturnType;

            Record.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
            assingExp.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
            codeGenerator.Emit(OpCodes.Stfld, recType.GetField(FieldName).RecordVariableBuilder);
        }
Example #3
0
 public override void SetAssingCode(ILGenerator codeGenerator, TypeBuilder typeBuilder, ModuleBuilder moduleBuilder, ExpressionNode assingExp)
 {
     var stdVarDecl = VarDeclaration as LetVariableDecNode;
     if (stdVarDecl != null)
     {
         assingExp.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
         codeGenerator.Emit(OpCodes.Stsfld, stdVarDecl.LetVariableBuilder);
         return;
     }
     var argVarDecl = (FunctionVariableDecNode)VarDeclaration;
     assingExp.GenerateCode(codeGenerator, typeBuilder, moduleBuilder);
     codeGenerator.Emit(OpCodes.Starg, argVarDecl.Index);
 }
Example #4
0
 public abstract void SetAssingCode(ILGenerator codeGenerator, TypeBuilder typeBuilder, ModuleBuilder moduleBuilder, ExpressionNode assingExp);