Skip to content

Commit 070052f

Browse files
committed
remove clippy annotations as much as possible
Signed-off-by: Yang Keao <[email protected]>
1 parent 7fe40e4 commit 070052f

File tree

4 files changed

+2
-4
lines changed

4 files changed

+2
-4
lines changed

build.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
// Copyright 2019 TiKV Project Authors. Licensed under Apache-2.0.
22
#[cfg(feature = "protobuf-codec")]
3-
#[allow(clippy::needless_borrows_for_generic_args)]
43
// Allow deprecated as TiKV pin versions to a outdated one.
54
fn generate_protobuf() {
65
use std::io::Write;

examples/profile_proto_with_prost.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// Copyright 2019 TiKV Project Authors. Licensed under Apache-2.0.
2+
23
use pprof::protos::Message;
34
use std::fs::File;
45
use std::io::Write;
@@ -103,7 +104,7 @@ fn main() {
103104
let profile = report.pprof().unwrap();
104105

105106
let mut content = Vec::new();
106-
//profile.encode(&mut content).unwrap(); # cargo tests fail with this enabled. encode doesn't seem to be recongized as a valid call.
107+
profile.encode(&mut content).unwrap();
107108
file.write_all(&content).unwrap();
108109

109110
println!("report: {:?}", report);

src/frames.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ impl UnresolvedFrames {
6262
}
6363
}
6464

65-
#[allow(clippy::map_all_any_identity)]
6665
impl PartialEq for UnresolvedFrames {
6766
fn eq(&self, other: &Self) -> bool {
6867
let (frames1, frames2) = (&self.frames, &other.frames);

src/profiler.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,6 @@ impl ProfilerGuard<'_> {
174174
}
175175
}
176176

177-
#[allow(clippy::needless_lifetimes)]
178177
impl<'a> Drop for ProfilerGuard<'a> {
179178
fn drop(&mut self) {
180179
drop(self.timer.take());

0 commit comments

Comments
 (0)