Github user srowen commented on a diff in the pull request:
https://github.com/apache/spark/pull/15093#discussion_r78746309
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
---
@@ -1659,7 +1659,8 @@ class Analyzer(
// child of it.
var currentChild = child
var i = 0
- while (i < groupedWindowExpressions.size) {
+ val size = groupedWindowExpressions.size
+ while (i < size) {
--- End diff --
In cases like this, can we use `fold` or an equivalent functional idiom to
make this even simpler and possibly more efficient?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]