presto-parser/src/main/java/io/prestosql/sql/parser/AstBuilder.java/AstBuilder/isDistinct
class AstBuilder:    private static boolean isDistinct(SqlBaseParser.SetQuantifierContext setQuantifier)
    {
        return setQuantifier != null && setQuantifier.DISTINCT() != null;
    }