kosiew commented on code in PR #23063:
URL: https://github.com/apache/datafusion/pull/23063#discussion_r3563665326
##########
datafusion/expr/src/expr.rs:
##########
@@ -930,21 +930,32 @@ pub struct ScalarFunction {
pub func: Arc<crate::ScalarUDF>,
/// List of expressions to feed to the functions as arguments
pub args: Vec<Expr>,
+ /// Original source code location, if known
+ pub spans: Spans,
Review Comment:
Could we avoid adding `spans` as a required public field on these expression
structs?
`ScalarFunction`, `AggregateFunction`, and `WindowFunction` are public and
can be constructed with struct literals. Adding a new required field means
existing downstream code using those literals will no longer compile. The
semver check reports `constructible_struct_adds_field` for all three structs.
Please keep the diagnostic span storage outside these public constructible
layouts, or use another semver-compatible design. The new required public
fields should be removed before merge.
--
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]