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_r400963183
 
 

 ##########
 File path: core/src/main/java/org/apache/calcite/rel/core/Sort.java
 ##########
 @@ -157,6 +157,11 @@ public RelNode accept(RexShuttle shuttle) {
     return copy(traitSet, getInput(), collation, offset, fetch);
   }
 
+  @Override public boolean isEnforcer() {
+    return offset == null && fetch == null
 
 Review comment:
   If they are not null, that means it is a LIMIT operator, which is not an 
enforcer. I already give the definition of Enforcer in RelNode interface. An 
enforcer should be known when it is created, if the operator can't tell by 
itself it is an enforcer or not, it is either the design's problem, or just 
leave it as a non-enforcer. 
   

----------------------------------------------------------------
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