szehon-ho opened a new pull request, #58363: URL: https://github.com/apache/spark/pull/58363
### What changes were proposed in this pull request? Clarify the `BoundFunction.equals` documentation by: - adding valid aggregate-query rejection to the existing list of consequences when separately bound functions do not compare equal; - adding concise connector examples for stateless functions and functions with bound state; and - correcting nearby test comments that implied `UnboundFunction.bind` must return a fresh instance. ### Why are the changes needed? The current documentation says missed equality matches affect performance only. However, if repeated scalar function calls bind to distinct objects that do not compare equal, a query that selects and groups by the same call may fail with `MISSING_AGGREGATION`. Also, `UnboundFunction.bind` permits both shared and newly created bound-function instances. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Documentation and test-comment changes only. `git diff --check` passed. ### Was this patch authored or co-authored using generative AI tooling? Generated-by: OpenAI Codex -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
