Ejemplo n.º 1
0
        private static Expression CompileExistence(Op op, Scope scope)
        {
            var p = scope.FreeVariable("ref");

            var @ref = new Literal {Value = p.Name};
            var fst = new Parens {Body = new Assign {Variable = @ref, Value = op.First}};

            return Compile(new If {Condition = new Existence {Expression = fst}, Body = @ref, ElseBody = op.Second}, scope);
        }
Ejemplo n.º 2
0
 public static Expression CompileParens(Parens node, Scope scope)
 {
     return Compile(node.Body, scope);
 }