presto-parser/src/main/java/io/prestosql/sql/tree/DefaultTraversalVisitor.java/DefaultTraversalVisitor/visitQuery
class DefaultTraversalVisitor:    @Override
    protected R visitQuery(Query node, C context)
    {
        if (node.getWith().isPresent()) {
            process(node.getWith().get(), context);
        }
        process(node.getQueryBody(), context);
        if (node.getOrderBy().isPresent()) {
            process(node.getOrderBy().get(), context);
        }

        return null;
    }