This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +7
-18
lines changed Expand file tree Collapse file tree 3 files changed +7
-18
lines changed Original file line number Diff line number Diff line change @@ -470,10 +470,7 @@ pub(crate) fn codegen_terminator_call<'tcx>(
470470 // FIXME find a cleaner way to support varargs
471471 if fn_sig. c_variadic {
472472 if !matches ! ( fn_sig. abi, Abi :: C { .. } ) {
473- fx. tcx . sess . span_fatal (
474- span,
475- & format ! ( "Variadic call for non-C abi {:?}" , fn_sig. abi) ,
476- ) ;
473+ fx. tcx . sess . span_fatal ( span, & format ! ( "Variadic call for non-C abi {:?}" , fn_sig. abi) ) ;
477474 }
478475 let sig_ref = fx. bcx . func . dfg . call_signature ( call_inst) . unwrap ( ) ;
479476 let abi_params = call_args
Original file line number Diff line number Diff line change @@ -839,18 +839,15 @@ fn codegen_stmt<'tcx>(
839839 StatementKind :: CopyNonOverlapping ( inner) => {
840840 let dst = codegen_operand ( fx, & inner. dst ) ;
841841 let pointee = dst
842- . layout ( )
843- . pointee_info_at ( fx, rustc_target:: abi:: Size :: ZERO )
844- . expect ( "Expected pointer" ) ;
842+ . layout ( )
843+ . pointee_info_at ( fx, rustc_target:: abi:: Size :: ZERO )
844+ . expect ( "Expected pointer" ) ;
845845 let dst = dst. load_scalar ( fx) ;
846846 let src = codegen_operand ( fx, & inner. src ) . load_scalar ( fx) ;
847847 let count = codegen_operand ( fx, & inner. count ) . load_scalar ( fx) ;
848848 let elem_size: u64 = pointee. size . bytes ( ) ;
849- let bytes = if elem_size != 1 {
850- fx. bcx . ins ( ) . imul_imm ( count, elem_size as i64 )
851- } else {
852- count
853- } ;
849+ let bytes =
850+ if elem_size != 1 { fx. bcx . ins ( ) . imul_imm ( count, elem_size as i64 ) } else { count } ;
854851 fx. bcx . call_memcpy ( fx. cx . module . target_config ( ) , dst, src, bytes) ;
855852 }
856853 }
Original file line number Diff line number Diff line change 1- #![ feature(
2- rustc_private,
3- decl_macro,
4- never_type,
5- hash_drain_filter
6- ) ]
1+ #![ feature( rustc_private, decl_macro, never_type, hash_drain_filter) ]
72#![ warn( rust_2018_idioms) ]
83#![ warn( unused_lifetimes) ]
94#![ warn( unreachable_pub) ]
You can’t perform that action at this time.
0 commit comments