zzwqqq commented on code in PR #5385: URL: https://github.com/apache/calcite/pull/5385#discussion_r4610998609
########## core/src/main/java/org/apache/calcite/sql2rel/CorrelationReferences.java: ########## @@ -36,11 +36,14 @@ import java.util.Set; -/** Conservatively analyzes references to correlation bindings outside a - * relational tree without changing it. +/** Checks for references to correlation bindings outside a relational tree. * - * <p>Local bindings hide references only within their scope. Regions with - * unknown expression coverage or binding scopes may contain outer references. */ + * <p>Records whether outer bindings may be referenced and which declared + * fields may still be needed. + * + * <p>A local binding hides the outer binding with the same id in its scope. Review Comment: Thanks. This analysis follows the existing binding scopes. With unique binding IDs, the same-ID shadowing checks would no longer be needed. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
