args[i] = expr.getArg(i).accept(this, c);
context.add(c);
}
if (context.replace) {
if (expr.getType().equals(Boolean.class)) {
Predicate predicate = new PredicateOperation((Operator<Boolean>)expr.getOperator(), ImmutableList.copyOf(args));
return !context.paths.isEmpty() ? exists(context, predicate) : predicate;
} else {
return new OperationImpl(expr.getType(), expr.getOperator(), ImmutableList.copyOf(args));
}
} else {