laurentgo commented on a change in pull request #1309: [CALCITE-3183] Trimming 
method for Filter rel uses wrong traitSet
URL: https://github.com/apache/calcite/pull/1309#discussion_r302655859
 
 

 ##########
 File path: core/src/main/java/org/apache/calcite/tools/RelBuilder.java
 ##########
 @@ -1164,7 +1176,8 @@ public RelBuilder filter(Iterable<? extends RexNode> 
predicates) {
 
     if (!simplifiedPredicates.isAlwaysTrue()) {
       final Frame frame = stack.pop();
-      final RelNode filter = filterFactory.createFilter(frame.rel, 
simplifiedPredicates);
+      final RelNode filter = filterFactory.createFilter(frame.rel,
+          simplifiedPredicates, Lists.newArrayList(correlVariables));
 
 Review comment:
   Usage of `Lists#newArrayList` is deprecated. Use `new ArrayList<>()` instead.
   
   It feels like `FilterFactory` should actually accept `Iterable<? extends 
RexNode>` predicates too, as well as constructors, to avoid unnecessary copies.

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to