super(codeModel, invoker, primitive);
}
@Override
protected void apply(JBlock parent) {
JvmMethod overload = primitive.getOverloads().get(0);
parser = new VarArgParser(this, parent, overload);
convertArgs(parser.getArgumentProcessingBlock());
// try S3 dispatch
genericDispatchStrategy.beforePrimitiveCalled(parent, parser, this, call);
// finally invoke the underlying function
JInvocation invocation = classRef(overload.getDeclaringClass()).staticInvoke(overload.getName());
for(JExpression argument : parser.getArguments()) {
invocation.arg(argument);
}
CodeModelUtils.returnSexp(codeModel, parent, overload, invocation);