fix: Performance improvements #804
conventional-prs.yml
on: pull_request_target
title-format
2s
Annotations
33 warnings
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/verify/seqvars.rs#L44
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/verify/seqvars.rs:44:17
|
44 | #[arg(long, default_value_t = false)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/verify/seqvars.rs#L40
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/verify/seqvars.rs:40:17
|
40 | #[arg(long, default_value_t = true)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/server/mod.rs#L33
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/server/mod.rs:33:17
|
33 | #[arg(long, default_value_t = 8080)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/server/mod.rs#L26
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/server/mod.rs:26:17
|
26 | #[arg(long, default_value_t = false)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2772
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2772:17
|
2772 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2590
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2590:17
|
2590 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2489
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2489:17
|
2489 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2393
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2393:13
|
2393 | entries[sample_no].name = samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2333
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2333:17
|
2333 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2219
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2219:17
|
2219 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2123
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2123:17
|
2123 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L2048
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:2048:17
|
2048 | entries[sample_no].name = self.samples[sample_no].clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `entries[sample_no].name.clone_from(&self.samples[sample_no])`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L1881
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:1881:13
|
1881 | tsv_record.chromosome2 = tsv_record.chromosome.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.chromosome2.clone_from(&tsv_record.chromosome)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/strucvars/mod.rs#L1875
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/strucvars/mod.rs:1875:13
|
1875 | tsv_record.chromosome2 = bnd.chrom.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.chromosome2.clone_from(&bnd.chrom)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/strucvars/mod.rs#L89
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/strucvars/mod.rs:89:17
|
89 | #[arg(long, default_value_t = 50)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/strucvars/mod.rs#L86
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/strucvars/mod.rs:86:17
|
86 | #[arg(long, default_value_t = 50)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/strucvars/mod.rs#L83
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/strucvars/mod.rs:83:17
|
83 | #[arg(long, default_value_t = 0.8)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
this expression creates a reference which is immediately dereferenced by the compiler:
src/annotate/seqvars/mod.rs#L1649
warning: this expression creates a reference which is immediately dereferenced by the compiler
--> src/annotate/seqvars/mod.rs:1649:37
|
1649 | let annotator = setup_annotator(&args, assembly)?;
| ^^^^^ help: change this to: `args`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
= note: `#[warn(clippy::needless_borrow)]` on by default
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/seqvars/mod.rs#L1130
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/seqvars/mod.rs:1130:25
|
1130 | tsv_record.refseq_hgvs_p = ann.hgvs_p.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.refseq_hgvs_p.clone_from(&ann.hgvs_p)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/seqvars/mod.rs#L1129
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/seqvars/mod.rs:1129:25
|
1129 | tsv_record.refseq_hgvs_c = ann.hgvs_t.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.refseq_hgvs_c.clone_from(&ann.hgvs_t)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/seqvars/mod.rs#L1101
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/seqvars/mod.rs:1101:25
|
1101 | tsv_record.ensembl_hgvs_p = ann.hgvs_p.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.ensembl_hgvs_p.clone_from(&ann.hgvs_p)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
|
assigning the result of `Clone::clone()` may be inefficient:
src/annotate/seqvars/mod.rs#L1100
warning: assigning the result of `Clone::clone()` may be inefficient
--> src/annotate/seqvars/mod.rs:1100:25
|
1100 | tsv_record.ensembl_hgvs_c = ann.hgvs_t.clone();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `tsv_record.ensembl_hgvs_c.clone_from(&ann.hgvs_t)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
= note: `#[warn(clippy::assigning_clones)]` on by default
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/seqvars/mod.rs#L107
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/seqvars/mod.rs:107:17
|
107 | #[arg(long, default_value_t = false)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/seqvars/mod.rs#L103
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/seqvars/mod.rs:103:17
|
103 | #[arg(long, default_value_t = true)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/seqvars/mod.rs#L100
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/seqvars/mod.rs:100:29
|
100 | #[arg(long, value_enum, default_value_t = csq::TranscriptSource::Both)]
| ^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
|
current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`:
src/annotate/seqvars/ann.rs#L390
warning: current MSRV (Minimum Supported Rust Version) is `1.64.0` but this item is stable since `1.70.0`
--> src/annotate/seqvars/ann.rs:390:5
|
390 | FromStr,
| ^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#incompatible_msrv
= note: `#[warn(clippy::incompatible_msrv)]` on by default
= note: this warning originates in the derive macro `FromStr` (in Nightly builds, run with -Z macro-backtrace for more info)
|
unused variable: `header`:
src/annotate/seqvars/mod.rs#L596
warning: unused variable: `header`
--> src/annotate/seqvars/mod.rs:596:9
|
596 | header: &VcfHeader,
| ^^^^^^ help: if this is intentional, prefix it with an underscore: `_header`
|
= note: `#[warn(unused_variables)]` on by default
|
bound is defined in more than one place:
src/common/io/std.rs#L73
warning: bound is defined in more than one place
--> src/common/io/std.rs:73:19
|
73 | pub fn read_lines<P: AsRef<Path>>(
| ^
...
77 | P: AsRef<Path>,
| ^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations
= note: `#[warn(clippy::multiple_bound_locations)]` on by default
|
unused import: `crate::finalize_buf_writer`:
src/annotate/seqvars/mod.rs#L55
warning: unused import: `crate::finalize_buf_writer`
--> src/annotate/seqvars/mod.rs:55:5
|
55 | use crate::finalize_buf_writer;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
unused import: `noodles_vcf::reader::Builder as VariantReaderBuilder`:
src/annotate/seqvars/mod.rs#L31
warning: unused import: `noodles_vcf::reader::Builder as VariantReaderBuilder`
--> src/annotate/seqvars/mod.rs:31:5
|
31 | use noodles_vcf::reader::Builder as VariantReaderBuilder;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
unused import: `noodles_bgzf::Writer as BgzfWriter`:
src/annotate/seqvars/mod.rs#L25
warning: unused import: `noodles_bgzf::Writer as BgzfWriter`
--> src/annotate/seqvars/mod.rs:25:5
|
25 | use noodles_bgzf::Writer as BgzfWriter;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
unused import: `futures::future::BoxFuture`:
src/annotate/seqvars/mod.rs#L24
warning: unused import: `futures::future::BoxFuture`
--> src/annotate/seqvars/mod.rs:24:5
|
24 | use futures::future::BoxFuture;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
unused import: `BufWriter`:
src/annotate/seqvars/mod.rs#L6
warning: unused import: `BufWriter`
--> src/annotate/seqvars/mod.rs:6:15
|
6 | use std::io::{BufWriter, Cursor, Read, Write};
| ^^^^^^^^^
|
= note: `#[warn(unused_imports)]` on by default
|