hsyuan commented on a change in pull request #1860: [CALCITE-2970] Add 
abstractConverter only between derived and required traitset
URL: https://github.com/apache/calcite/pull/1860#discussion_r400956153
 
 

 ##########
 File path: core/src/main/java/org/apache/calcite/plan/volcano/RelSet.java
 ##########
 @@ -160,107 +162,106 @@ void obliterateRelNode(RelNode rel) {
   public RelSubset add(RelNode rel) {
     assert equivalentSet == null : "adding to a dead set";
     final RelTraitSet traitSet = rel.getTraitSet().simplify();
-    final RelSubset subset = getOrCreateSubset(rel.getCluster(), traitSet);
+    final RelSubset subset = getOrCreateSubset(
+        rel.getCluster(), traitSet, rel.isEnforcer());
     subset.add(rel);
     return subset;
   }
 
+  /**
+   * If the subset is required, convert derived subsets to this subset.
 
 Review comment:
   It is ok to say that. Because we will call `relsubset. isRequired()` and 
`relsubset.isDerived()` on RelSubSet.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to