presto-main/src/main/java/io/prestosql/sql/planner/sanity/NoDuplicatePlanNodeIdsChecker.java/NoDuplicatePlanNodeIdsChecker/validate
class NoDuplicatePlanNodeIdsChecker:    @Override
    public void validate(PlanNode planNode, Session session, Metadata metadata, TypeAnalyzer typeAnalyzer, TypeProvider types, WarningCollector warningCollector)
    {
        Map<PlanNodeId, PlanNode> planNodeIds = new HashMap<>();
        searchFrom(planNode)
                .findAll()
                .forEach(node -> planNodeIds.merge(node.getId(), node, this::reportDuplicateId));
    }