Ejemplo n.º 1
0
 public override void Visit(ReturnExpression expression)
 {
     expression.Expression.Visit(this);
     this.block.CompileByteCode(ByteCode.ReturnPop);
 }
Ejemplo n.º 2
0
 public abstract void Visit(ReturnExpression expression);
Ejemplo n.º 3
0
        public override void Visit(ReturnExpression expression)
        {
            if (this.CurrentMethod != null && this.inBlock)
            {
                this.writer.Write("__context.value = ");
                expression.Expression.Visit(this);
                this.writer.WriteLine(";");
                this.writer.WriteLine("__context.return = true;");
                this.writer.Write("return __context.value");
                return;
            }

            this.writer.Write("return ");
            expression.Expression.Visit(this);
        }