presto-main/src/main/java/io/prestosql/sql/planner/iterative/rule/RemoveUnreferencedScalarSubqueries.java/RemoveUnreferencedScalarSubqueries/isUnreferencedScalar
class RemoveUnreferencedScalarSubqueries:    private boolean isUnreferencedScalar(PlanNode planNode, Lookup lookup)
    {
        return planNode.getOutputSymbols().isEmpty() && isScalar(planNode, lookup);
    }