Toby1009 opened a new pull request, #25967:
URL: https://github.com/apache/datafusion/pull/25967

   ## Which issue does this PR close?
   
   - Closes #25925.
   
   ## Rationale for this change
   
   The time arithmetic SQL tests added in #25668 retain their sorts even when 
scalar UDF type recovery is removed, because ordinary arithmetic already treats 
unbounded results as potentially overflowing. Checked arithmetic needs the 
recovered time type to detect wrapping across midnight, so it provides a 
regression test for that interaction.
   
   ## What changes are included in this PR?
   
   - Add a checked `date_trunc('hour', t) + INTERVAL '2 hours'` property test 
over ordered Time64 input. Assert that truncation preserves ordering before 
checking that time arithmetic drops it.
   - Cover an override returning unbounded Null bounds, and separate 
bounds-preservation tests from error propagation.
   - Clarify which intervals are replaced or preserved and that direct 
`PhysicalExpr::evaluate_bounds` calls bypass the fallback.
   
   ## What is the testing strategy for this PR?
   
   The new checked arithmetic test passes with type recovery and fails with 
`Ordered` instead of `Unordered` when the fallback is removed. Existing SQL 
tests are retained.
   
   Validation: `cargo clippy --all-targets --all-features -- -D warnings`, 
`./dev/rust_lint.sh`, the extended workspace test suite, and all 8 
scalar-function unit tests. Ablation checks confirm that removing type recovery 
fails the ordering assertion, and making the truncated child unordered fails 
the new precondition assertion.
   
   ## Are there any user-facing changes?
   
   UDF bounds documentation is more precise. Execution behavior and public APIs 
are unchanged.
   


-- 
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]

Reply via email to