Merge pull request #993 from MaxVerevkin/deny-unused-mut
deny unused_mut and unused_variables
This commit is contained in:
commit
5d9dbb62ef
|
@ -195,7 +195,7 @@ where
|
||||||
unsafe fn reallocate_copy(
|
unsafe fn reallocate_copy(
|
||||||
rto: Const<RTO>,
|
rto: Const<RTO>,
|
||||||
cto: Const<CTO>,
|
cto: Const<CTO>,
|
||||||
mut buf: <Self as Allocator<T, RFrom, CFrom>>::Buffer,
|
buf: <Self as Allocator<T, RFrom, CFrom>>::Buffer,
|
||||||
) -> ArrayStorage<MaybeUninit<T>, RTO, CTO> {
|
) -> ArrayStorage<MaybeUninit<T>, RTO, CTO> {
|
||||||
let mut res = <Self as Allocator<T, Const<RTO>, Const<CTO>>>::allocate_uninit(rto, cto);
|
let mut res = <Self as Allocator<T, Const<RTO>, Const<CTO>>>::allocate_uninit(rto, cto);
|
||||||
|
|
||||||
|
@ -226,7 +226,7 @@ where
|
||||||
unsafe fn reallocate_copy(
|
unsafe fn reallocate_copy(
|
||||||
rto: Dynamic,
|
rto: Dynamic,
|
||||||
cto: CTo,
|
cto: CTo,
|
||||||
mut buf: ArrayStorage<T, RFROM, CFROM>,
|
buf: ArrayStorage<T, RFROM, CFROM>,
|
||||||
) -> VecStorage<MaybeUninit<T>, Dynamic, CTo> {
|
) -> VecStorage<MaybeUninit<T>, Dynamic, CTo> {
|
||||||
let mut res = <Self as Allocator<T, Dynamic, CTo>>::allocate_uninit(rto, cto);
|
let mut res = <Self as Allocator<T, Dynamic, CTo>>::allocate_uninit(rto, cto);
|
||||||
|
|
||||||
|
@ -257,7 +257,7 @@ where
|
||||||
unsafe fn reallocate_copy(
|
unsafe fn reallocate_copy(
|
||||||
rto: RTo,
|
rto: RTo,
|
||||||
cto: Dynamic,
|
cto: Dynamic,
|
||||||
mut buf: ArrayStorage<T, RFROM, CFROM>,
|
buf: ArrayStorage<T, RFROM, CFROM>,
|
||||||
) -> VecStorage<MaybeUninit<T>, RTo, Dynamic> {
|
) -> VecStorage<MaybeUninit<T>, RTo, Dynamic> {
|
||||||
let mut res = <Self as Allocator<T, RTo, Dynamic>>::allocate_uninit(rto, cto);
|
let mut res = <Self as Allocator<T, RTo, Dynamic>>::allocate_uninit(rto, cto);
|
||||||
|
|
||||||
|
|
|
@ -693,7 +693,7 @@ impl<T, R: Dim, C: Dim, S: RawStorage<T, R, C>> Matrix<T, R, C, S> {
|
||||||
#[inline]
|
#[inline]
|
||||||
fn transpose_to_uninit<Status, R2, C2, SB>(
|
fn transpose_to_uninit<Status, R2, C2, SB>(
|
||||||
&self,
|
&self,
|
||||||
status: Status,
|
_status: Status,
|
||||||
out: &mut Matrix<Status::Value, R2, C2, SB>,
|
out: &mut Matrix<Status::Value, R2, C2, SB>,
|
||||||
) where
|
) where
|
||||||
Status: InitStatus<T>,
|
Status: InitStatus<T>,
|
||||||
|
@ -1389,7 +1389,7 @@ impl<T: SimdComplexField, R: Dim, C: Dim, S: RawStorage<T, R, C>> Matrix<T, R, C
|
||||||
#[inline]
|
#[inline]
|
||||||
fn adjoint_to_uninit<Status, R2, C2, SB>(
|
fn adjoint_to_uninit<Status, R2, C2, SB>(
|
||||||
&self,
|
&self,
|
||||||
status: Status,
|
_status: Status,
|
||||||
out: &mut Matrix<Status::Value, R2, C2, SB>,
|
out: &mut Matrix<Status::Value, R2, C2, SB>,
|
||||||
) where
|
) where
|
||||||
Status: InitStatus<T>,
|
Status: InitStatus<T>,
|
||||||
|
|
|
@ -42,14 +42,14 @@ where
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
fn replace(&mut self, i: usize, val: Self::Element) {
|
fn replace(&mut self, i: usize, val: Self::Element) {
|
||||||
self.zip_apply(&val, |mut a, b| {
|
self.zip_apply(&val, |a, b| {
|
||||||
a.replace(i, b);
|
a.replace(i, b);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
unsafe fn replace_unchecked(&mut self, i: usize, val: Self::Element) {
|
unsafe fn replace_unchecked(&mut self, i: usize, val: Self::Element) {
|
||||||
self.zip_apply(&val, |mut a, b| {
|
self.zip_apply(&val, |a, b| {
|
||||||
a.replace_unchecked(i, b);
|
a.replace_unchecked(i, b);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -146,7 +146,7 @@ macro_rules! componentwise_binop_impl(
|
||||||
#[inline]
|
#[inline]
|
||||||
fn $method_to_statically_unchecked_uninit<Status, R2: Dim, C2: Dim, SB,
|
fn $method_to_statically_unchecked_uninit<Status, R2: Dim, C2: Dim, SB,
|
||||||
R3: Dim, C3: Dim, SC>(&self,
|
R3: Dim, C3: Dim, SC>(&self,
|
||||||
status: Status,
|
_status: Status,
|
||||||
rhs: &Matrix<T, R2, C2, SB>,
|
rhs: &Matrix<T, R2, C2, SB>,
|
||||||
out: &mut Matrix<Status::Value, R3, C3, SC>)
|
out: &mut Matrix<Status::Value, R3, C3, SC>)
|
||||||
where Status: InitStatus<T>,
|
where Status: InitStatus<T>,
|
||||||
|
@ -699,7 +699,7 @@ where
|
||||||
#[inline(always)]
|
#[inline(always)]
|
||||||
fn xx_mul_to_uninit<Status, R2: Dim, C2: Dim, SB, R3: Dim, C3: Dim, SC>(
|
fn xx_mul_to_uninit<Status, R2: Dim, C2: Dim, SB, R3: Dim, C3: Dim, SC>(
|
||||||
&self,
|
&self,
|
||||||
status: Status,
|
_status: Status,
|
||||||
rhs: &Matrix<T, R2, C2, SB>,
|
rhs: &Matrix<T, R2, C2, SB>,
|
||||||
out: &mut Matrix<Status::Value, R3, C3, SC>,
|
out: &mut Matrix<Status::Value, R3, C3, SC>,
|
||||||
dot: impl Fn(
|
dot: impl Fn(
|
||||||
|
|
|
@ -71,10 +71,11 @@ an optimized set of tools for computer graphics and physics. Those features incl
|
||||||
* Insertion and removal of rows of columns of a matrix.
|
* Insertion and removal of rows of columns of a matrix.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#![allow(unused_variables, unused_mut)]
|
|
||||||
#![deny(
|
#![deny(
|
||||||
missing_docs,
|
missing_docs,
|
||||||
nonstandard_style,
|
nonstandard_style,
|
||||||
|
unused_variables,
|
||||||
|
unused_mut,
|
||||||
unused_parens,
|
unused_parens,
|
||||||
unused_qualifications,
|
unused_qualifications,
|
||||||
unused_results,
|
unused_results,
|
||||||
|
|
Loading…
Reference in New Issue