@@ -9,15 +9,16 @@ macro_rules! simd_ty {
9
9
#[ derive( Copy , Clone , Debug , PartialEq ) ]
10
10
pub ( crate ) struct $id( $( pub $elem_ty) ,* ) ;
11
11
12
+ #[ cfg_attr( feature = "cargo-clippy" , allow( clippy:: use_self) ) ]
12
13
impl $id {
13
14
#[ inline]
14
15
pub ( crate ) const fn new( $( $elem_name: $elem_ty) ,* ) -> Self {
15
- Self ( $( $elem_name) ,* )
16
+ $id ( $( $elem_name) ,* )
16
17
}
17
18
18
19
#[ inline]
19
20
pub ( crate ) const fn splat( value: $ety) -> Self {
20
- Self ( $( {
21
+ $id ( $( {
21
22
#[ allow( non_camel_case_types, dead_code) ]
22
23
struct $elem_name;
23
24
value
@@ -40,6 +41,7 @@ macro_rules! simd_m_ty {
40
41
#[ derive( Copy , Clone , Debug , PartialEq ) ]
41
42
pub ( crate ) struct $id( $( pub $elem_ty) ,* ) ;
42
43
44
+ #[ cfg_attr( feature = "cargo-clippy" , allow( clippy:: use_self) ) ]
43
45
impl $id {
44
46
#[ inline]
45
47
const fn bool_to_internal( x: bool ) -> $ety {
@@ -48,12 +50,12 @@ macro_rules! simd_m_ty {
48
50
49
51
#[ inline]
50
52
pub ( crate ) const fn new( $( $elem_name: bool ) ,* ) -> Self {
51
- Self ( $( Self :: bool_to_internal( $elem_name) ) ,* )
53
+ $id ( $( Self :: bool_to_internal( $elem_name) ) ,* )
52
54
}
53
55
54
56
#[ inline]
55
57
pub ( crate ) const fn splat( value: bool ) -> Self {
56
- Self ( $( {
58
+ $id ( $( {
57
59
#[ allow( non_camel_case_types, dead_code) ]
58
60
struct $elem_name;
59
61
Self :: bool_to_internal( value)
0 commit comments