You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "RTEnzyme (via GitHub)" <gi...@apache.org> on 2023/04/08 06:50:42 UTC

[GitHub] [arrow-datafusion] RTEnzyme commented on a diff in pull request #5902: feat: Implement the bitwise_not in NotExpr

RTEnzyme commented on code in PR #5902:
URL: https://github.com/apache/arrow-datafusion/pull/5902#discussion_r1161073984


##########
datafusion/physical-expr/src/expressions/not.rs:
##########
@@ -59,8 +63,25 @@ impl PhysicalExpr for NotExpr {
         self
     }
 
-    fn data_type(&self, _input_schema: &Schema) -> Result<DataType> {
-        Ok(DataType::Boolean)
+    fn data_type(&self, input_schema: &Schema) -> Result<DataType> {
+        // Ok(DataType::Boolean)
+        let data_type = self.arg.data_type(input_schema)?;

Review Comment:
   As @alamb [suggestion](https://github.com/apache/arrow-datafusion/issues/5700#issuecomment-1481132344), I embed bitwise_not into NotExpr. But I agree that this way will break `NotExpr` original struct.  I think I should further discuss the implementation in the issue #5700



-- 
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-unsubscribe@arrow.apache.org

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