presto-main/src/main/java/io/prestosql/operator/aggregation/DecimalAverageAggregation.java/DecimalAverageAggregation/specialize
class DecimalAverageAggregation:    @Override
    public InternalAggregationFunction specialize(BoundVariables boundVariables, int arity, Metadata metadata)
    {
        Type type = metadata.getType(getOnlyElement(applyBoundVariables(getFunctionMetadata().getSignature().getArgumentTypes(), boundVariables)));
        return generateAggregation(type);
    }