File tree Expand file tree Collapse file tree 4 files changed +7
-8
lines changed Expand file tree Collapse file tree 4 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 1
1
use std:: hash:: Hash ;
2
2
3
3
use bigdecimal:: num_traits:: ToBytes ;
4
- use indexmap:: IndexMap ;
5
4
6
5
use crate :: binary:: Binary ;
7
6
use crate :: collection:: * ;
@@ -444,6 +443,7 @@ impl From<Array> for AmqpType {
444
443
#[ cfg( test) ]
445
444
mod tests {
446
445
use super :: * ;
446
+ use indexmap:: IndexMap ;
447
447
448
448
#[ test]
449
449
fn construct_null ( ) {
@@ -657,7 +657,7 @@ mod tests {
657
657
#[ test]
658
658
fn construct_list_with_less_than_255_elements_and_larger_than_255_bytes ( ) {
659
659
let mut arr = vec ! [ ] ;
660
- for i in 0 ..100 {
660
+ for _ in 0 ..100 {
661
661
arr. push ( "aaaaaaaaaaaaaaaaaaaa" . into ( ) ) ;
662
662
}
663
663
let val = AmqpType :: List ( arr. into ( ) ) ;
@@ -699,7 +699,7 @@ mod tests {
699
699
#[ test]
700
700
fn construct_array_with_less_than_255_elements_and_larger_than_255_bytes ( ) {
701
701
let mut arr = vec ! [ ] ;
702
- for i in 0 ..100 {
702
+ for _ in 0 ..100 {
703
703
arr. push ( "aaaaaaaaaaaaaaaaaaaa" . into ( ) ) ;
704
704
}
705
705
let val = AmqpType :: Array ( arr. into ( ) ) ;
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ impl Encode for Array {
52
52
impl From < EncodedVec > for Vec < u8 > {
53
53
fn from ( value : EncodedVec ) -> Self {
54
54
let mut res = Vec :: new ( ) ;
55
- for mut val in value. 0 {
55
+ for val in value. 0 {
56
56
let mut enc: Vec < u8 > = val. into ( ) ;
57
57
res. append ( & mut enc) ;
58
58
}
@@ -79,7 +79,7 @@ impl From<Vec<AmqpType>> for Array {
79
79
}
80
80
81
81
impl Hash for Map {
82
- fn hash < H : std:: hash:: Hasher > ( & self , state : & mut H ) {
82
+ fn hash < H : std:: hash:: Hasher > ( & self , _state : & mut H ) {
83
83
todo ! ( )
84
84
}
85
85
}
Original file line number Diff line number Diff line change 1
- use crate :: amqp_type:: { Constructor , Encode } ;
2
1
use bigdecimal:: BigDecimal ;
3
2
3
+ use crate :: amqp_type:: Encode ;
4
+
4
5
use super :: amqp_type:: Encoded ;
5
6
6
7
#[ derive( Hash , Eq , PartialEq ) ]
Original file line number Diff line number Diff line change @@ -2,8 +2,6 @@ use thiserror::Error;
2
2
3
3
#[ derive( Error , Debug ) ]
4
4
pub enum AppError {
5
- #[ error( "Malformed Frame: {0}" ) ]
6
- MalformedFrame ( & ' static str ) ,
7
5
#[ error( "Encountered an IO Error." ) ]
8
6
IoError ( #[ from] std:: io:: Error ) ,
9
7
}
You can’t perform that action at this time.
0 commit comments