Exemple #1
0
        protected override void DoGenerate(CilEmitter emitter)
        {
            valueExpr.EmitRValue(emitter);
            if (valueExpr.ReturnType == typeof(string))
            {
                emitter.EmitParse(variableUseExpr.ReturnType);
            }

            variableUseExpr.EmitAssignment();
        }
Exemple #2
0
        public override void EmitRValue(CilEmitter emitter)
        {
            valueExpr.EmitRValue(emitter);
            if (valueExpr.ReturnType == typeof(string))
            {
                emitter.EmitParse(variableUseExpr.ReturnType);
            }

            variableUseExpr.EmitAssignment();
            variableUseExpr.EmitRValue(emitter);
        }
Exemple #3
0
        protected override void DoGenerate(CilEmitter emitter)
        {
            symbol.Variable = emitter.EmitLocalVarDeclaration(symbol.Name, symbol.VariableType);

            if (initialValue != null)
            {
                initialValue.EmitRValue(emitter);
                if (initialValue.ReturnType == typeof(string))
                {
                    emitter.EmitParse(symbol.VariableType);
                }
                symbol.Variable.EmitAssignment();
            }
        }