presto-main/src/main/java/io/prestosql/sql/planner/iterative/rule/CanonicalizeExpressionRewriter.java/CanonicalizeExpressionRewriter/rewriteFormat
class CanonicalizeExpressionRewriter:        @Override
        public Expression rewriteFormat(Format node, Void context, ExpressionTreeRewriter<Void> treeRewriter)
        {
            List<Expression> arguments = node.getArguments().stream()
                    .map(value -> treeRewriter.rewrite(value, context))
                    .collect(toImmutableList());
            List<Type> argumentTypes = node.getArguments().stream()
                    .map(NodeRef::of)
                    .map(expressionTypes::get)
                    .collect(toImmutableList());

            return new FunctionCallBuilder(metadata)
                    .setName(QualifiedName.of(FormatFunction.NAME))
                    .addArgument(VARCHAR, arguments.get(0))
                    .addArgument(RowType.anonymous(argumentTypes.subList(1, arguments.size())), new Row(arguments.subList(1, arguments.size())))
                    .build();
        }