Search in sources :

Example 1 with BlockFunExpr

use of suite.jdk.gen.FunExprM.BlockFunExpr in project suite by stupidsing.

the class FunFactory method loop.

public FunExpr loop(Fun2<FunExpr, FunExpr, FunExpr> fun) {
    BlockFunExpr expr = new BlockFunExpr();
    Mutable<BlockFunExpr> m = Mutable.of(expr);
    BlockBreakFunExpr b = new BlockBreakFunExpr();
    b.block = m;
    BlockContFunExpr c = new BlockContFunExpr();
    c.block = m;
    expr.expr = fun.apply(b, c);
    return expr;
}
Also used : BlockBreakFunExpr(suite.jdk.gen.FunExprM.BlockBreakFunExpr) BlockFunExpr(suite.jdk.gen.FunExprM.BlockFunExpr) BlockContFunExpr(suite.jdk.gen.FunExprM.BlockContFunExpr)

Aggregations

BlockBreakFunExpr (suite.jdk.gen.FunExprM.BlockBreakFunExpr)1 BlockContFunExpr (suite.jdk.gen.FunExprM.BlockContFunExpr)1 BlockFunExpr (suite.jdk.gen.FunExprM.BlockFunExpr)1