This is an automated email from the ASF dual-hosted git repository.
alamb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow-rs.git
The following commit(s) were added to refs/heads/master by this push:
new 7449e2c Fix new clippy lints introduced in Rust 1.58 (#1170)
7449e2c is described below
commit 7449e2c6643445c3b24f956f50f13b512112299d
Author: Andrew Lamb <[email protected]>
AuthorDate: Fri Jan 14 11:17:36 2022 -0500
Fix new clippy lints introduced in Rust 1.58 (#1170)
---
arrow/src/buffer/immutable.rs | 1 +
arrow/src/util/test_util.rs | 2 +-
parquet/src/schema/printer.rs | 4 ++--
3 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/arrow/src/buffer/immutable.rs b/arrow/src/buffer/immutable.rs
index bd09702..b5174d3 100644
--- a/arrow/src/buffer/immutable.rs
+++ b/arrow/src/buffer/immutable.rs
@@ -244,6 +244,7 @@ impl std::ops::Deref for Buffer {
}
unsafe impl Sync for Buffer {}
+#[allow(clippy::non_send_fields_in_send_ty)]
unsafe impl Send for Buffer {}
impl From<MutableBuffer> for Buffer {
diff --git a/arrow/src/util/test_util.rs b/arrow/src/util/test_util.rs
index 6b1ad4b..cae148a 100644
--- a/arrow/src/util/test_util.rs
+++ b/arrow/src/util/test_util.rs
@@ -147,7 +147,7 @@ fn get_data_dir(udf_env: &str, submodule_data: &str) ->
Result<PathBuf, Box<dyn
"env `{}` is undefined or has empty value, and the pre-defined
data dir `{}` not found\n\
HINT: try running `git submodule update --init`",
udf_env,
- pb.display().to_string(),
+ pb.display(),
).into())
}
}
diff --git a/parquet/src/schema/printer.rs b/parquet/src/schema/printer.rs
index de1934f..b78bce7 100644
--- a/parquet/src/schema/printer.rs
+++ b/parquet/src/schema/printer.rs
@@ -246,7 +246,7 @@ fn print_logical_and_converted(
None => {
// Also print converted type if it is available
match converted_type {
- ConvertedType::NONE => format!(""),
+ ConvertedType::NONE => String::new(),
decimal @ ConvertedType::DECIMAL => {
// For decimal type we should print precision and scale if
they
// are > 0, e.g. DECIMAL(9,2) -
@@ -256,7 +256,7 @@ fn print_logical_and_converted(
format!("({},{})", p, s)
}
(p, 0) if p > 0 => format!("({})", p),
- _ => format!(""),
+ _ => String::new(),
};
format!("{}{}", decimal, precision_scale)
}