This is an automated email from the ASF dual-hosted git repository.
alamb pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-datafusion.git
The following commit(s) were added to refs/heads/main by this push:
new af26c66f70 Fixes for clippy 1.71 (#6959)
af26c66f70 is described below
commit af26c66f708080e00967e41513c39c72e6bde8d1
Author: Andrew Lamb <[email protected]>
AuthorDate: Thu Jul 13 13:58:25 2023 -0400
Fixes for clippy 1.71 (#6959)
---
datafusion/physical-expr/src/aggregate/hyperloglog.rs | 9 +++++++++
datafusion/sql/tests/sql_integration.rs | 14 +++++++-------
2 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/datafusion/physical-expr/src/aggregate/hyperloglog.rs
b/datafusion/physical-expr/src/aggregate/hyperloglog.rs
index bf25ecebcd..a0d55ca71d 100644
--- a/datafusion/physical-expr/src/aggregate/hyperloglog.rs
+++ b/datafusion/physical-expr/src/aggregate/hyperloglog.rs
@@ -68,6 +68,15 @@ const SEED: RandomState = RandomState::with_seeds(
0x0eaea5d736d733a4_u64,
);
+impl<T> Default for HyperLogLog<T>
+where
+ T: Hash + ?Sized,
+{
+ fn default() -> Self {
+ Self::new()
+ }
+}
+
impl<T> HyperLogLog<T>
where
T: Hash + ?Sized,
diff --git a/datafusion/sql/tests/sql_integration.rs
b/datafusion/sql/tests/sql_integration.rs
index 1dc0c491fd..652011fbac 100644
--- a/datafusion/sql/tests/sql_integration.rs
+++ b/datafusion/sql/tests/sql_integration.rs
@@ -37,13 +37,6 @@ use datafusion_sql::{
use rstest::rstest;
-#[cfg(test)]
-#[ctor::ctor]
-fn init() {
- // Enable RUST_LOG logging configuration for tests
- let _ = env_logger::try_init();
-}
-
#[test]
fn parse_decimals() {
let test_data = [
@@ -4161,3 +4154,10 @@ impl TableSource for EmptyTable {
self.table_schema.clone()
}
}
+
+#[cfg(test)]
+#[ctor::ctor]
+fn init() {
+ // Enable RUST_LOG logging configuration for tests
+ let _ = env_logger::try_init();
+}