presto-main/src/main/java/io/prestosql/sql/planner/optimizations/OptimizeMixedDistinctAggregations.java/Optimizer/checkAllEquatableTypes
class Optimizer:        private boolean checkAllEquatableTypes(AggregateInfo aggregateInfo)
        {
            for (Symbol symbol : aggregateInfo.getOriginalNonDistinctAggregateArgs()) {
                Type type = symbolAllocator.getTypes().get(symbol);
                if (!type.isComparable()) {
                    return false;
                }
            }

            if (!symbolAllocator.getTypes().get(aggregateInfo.getMask()).isComparable()) {
                return false;
            }

            return true;
        }