File tree Expand file tree Collapse file tree 5 files changed +6
-9
lines changed Expand file tree Collapse file tree 5 files changed +6
-9
lines changed Original file line number Diff line number Diff line change 1
- indent_style =" Block"
2
- imports_indent =" Block"
3
1
use_try_shorthand =true
4
2
use_field_init_shorthand =true
5
- merge_imports =true
Original file line number Diff line number Diff line change 1
1
language : rust
2
- rust : nightly
3
2
before_script :
4
3
- rustup component add rustfmt-preview
5
4
script :
Original file line number Diff line number Diff line change @@ -84,9 +84,9 @@ impl LuaBytecode {
84
84
85
85
impl fmt:: Display for LuaBytecode {
86
86
fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result {
87
- write ! ( f, "{{\n " ) ;
87
+ write ! ( f, "{{\n " ) ? ;
88
88
for instr in & self . block {
89
- write ! ( f, " {}\n " , instr) ;
89
+ write ! ( f, " {}\n " , instr) ? ;
90
90
}
91
91
write ! ( f, "}}" )
92
92
}
Original file line number Diff line number Diff line change @@ -177,7 +177,7 @@ mod tests {
177
177
#[ test]
178
178
fn registers_are_retrieved_in_the_correct_order ( ) {
179
179
let mut rm = RegisterMap :: new ( ) ;
180
- for i in 0 ..3 {
180
+ for _ in 0 ..3 {
181
181
rm. push_scope ( ) ;
182
182
rm. create_reg ( "foo" ) ;
183
183
}
Original file line number Diff line number Diff line change @@ -321,7 +321,7 @@ mod tests {
321
321
let bar_get = main. get_attr ( "bar" ) . unwrap ( ) ;
322
322
assert_eq ! ( bar_get. kind( ) , LuaValKind :: INT ) ;
323
323
assert_eq ! ( bar_get. to_int( ) . unwrap( ) , 2 ) ;
324
- main. set_attr ( "bar" , LuaVal :: from ( 2.0 ) ) ;
324
+ main. set_attr ( "bar" , LuaVal :: from ( 2.0 ) ) . unwrap ( ) ;
325
325
let bar_get = main. get_attr ( "bar" ) . unwrap ( ) ;
326
326
assert_eq ! ( bar_get. kind( ) , LuaValKind :: FLOAT ) ;
327
327
assert_float_absolute_eq ! ( bar_get. to_float( ) . unwrap( ) , 2.0 , 0.1 ) ;
@@ -553,7 +553,8 @@ mod tests {
553
553
table2
554
554
. get_attr ( "foo" )
555
555
. unwrap ( )
556
- . set_attr ( "foo" , LuaVal :: from ( 2 ) ) ;
556
+ . set_attr ( "foo" , LuaVal :: from ( 2 ) )
557
+ . unwrap ( ) ;
557
558
assert_eq ! (
558
559
table3
559
560
. get_attr( "foo" )
You can’t perform that action at this time.
0 commit comments