berkaysynnada commented on code in PR #14699:
URL: https://github.com/apache/datafusion/pull/14699#discussion_r1963766084


##########
datafusion/expr-common/src/interval_arithmetic.rs:
##########
@@ -405,13 +406,18 @@ impl Interval {
 
         // There must be no way to create an interval whose endpoints have
         // different types.
-        assert!(
+        debug_assert!(

Review Comment:
   > What's the rational in moving from an assert to debug assert
   Panicking on this assert!() is impossible in any path along the current 
codebase (so no need it in an optimized build). If someone gets in and does 
some modifications, this check should be there to guide developer.
   
   >  can we do validation in constructor hre 
https://github.com/apache/datafusion/pull/14699/files#diff-2a1941b7d923645151db0a34095b2d1dff5671eaa1103ec6111d0de21c31f5c3L293
 and remove the assert?
   I couldn't track where you point out



-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to