public ExpressionFunction withArgument(String argument) {
        if (arguments.contains(argument)) return this;

        List<String> arguments = new ArrayList<>(this.arguments);
        arguments.add(argument);
        return new ExpressionFunction(name, arguments, body, argumentTypes, returnType);
    }
Returns a copy of this with the given argument added (if not already present)
searchlib/src/main/java/com/yahoo/searchlib/rankingexpression/ExpressionFunction.java