kosiew commented on code in PR #22792:
URL: https://github.com/apache/datafusion/pull/22792#discussion_r3377138492


##########
datafusion/common/src/stats.rs:
##########
@@ -318,6 +318,15 @@ impl Precision<ScalarValue> {
     }
 }
 
+impl<T: Debug + Clone + PartialEq + Eq + PartialOrd> From<Option<T>> for 
Precision<T> {
+    fn from(option: Option<T>) -> Self {

Review Comment:
   Small readability suggestion: this `Option` match can be collapsed without 
changing behavior. This keeps the mapping from `Some` to `Exact` and `None` to 
`Absent` pretty direct:
   
   ```rust
   option.map_or(Precision::Absent, Precision::Exact)
   ```



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