@@ -47,12 +47,12 @@ pub(crate) fn conv_to_call_conv(sess: &Session, c: Conv, default_call_conv: Call
4747 }
4848
4949 Conv :: X86Intr | Conv :: RiscvInterrupt { .. } => {
50- sess. fatal ( format ! ( "interrupt call conv {c:?} not yet implemented" ) )
50+ sess. dcx ( ) . fatal ( format ! ( "interrupt call conv {c:?} not yet implemented" ) )
5151 }
5252
53- Conv :: ArmAapcs => sess. fatal ( "aapcs call conv not yet implemented" ) ,
53+ Conv :: ArmAapcs => sess. dcx ( ) . fatal ( "aapcs call conv not yet implemented" ) ,
5454 Conv :: CCmseNonSecureCall => {
55- sess. fatal ( "C-cmse-nonsecure-call call conv is not yet implemented" ) ;
55+ sess. dcx ( ) . fatal ( "C-cmse-nonsecure-call call conv is not yet implemented" ) ;
5656 }
5757
5858 Conv :: Msp430Intr
@@ -88,10 +88,10 @@ pub(crate) fn import_function<'tcx>(
8888 let sig = get_function_sig ( tcx, module. target_config ( ) . default_call_conv , inst) ;
8989 match module. declare_function ( name, Linkage :: Import , & sig) {
9090 Ok ( func_id) => func_id,
91- Err ( ModuleError :: IncompatibleDeclaration ( _) ) => tcx. sess . fatal ( format ! (
91+ Err ( ModuleError :: IncompatibleDeclaration ( _) ) => tcx. dcx ( ) . fatal ( format ! (
9292 "attempt to declare `{name}` as function, but it was already declared as static"
9393 ) ) ,
94- Err ( ModuleError :: IncompatibleSignature ( _, prev_sig, new_sig) ) => tcx. sess . fatal ( format ! (
94+ Err ( ModuleError :: IncompatibleSignature ( _, prev_sig, new_sig) ) => tcx. dcx ( ) . fatal ( format ! (
9595 "attempt to declare `{name}` with signature {new_sig:?}, \
9696 but it was already declared with signature {prev_sig:?}"
9797 ) ) ,
@@ -181,7 +181,7 @@ fn make_local_place<'tcx>(
181181 is_ssa : bool ,
182182) -> CPlace < ' tcx > {
183183 if layout. is_unsized ( ) {
184- fx. tcx . sess . span_fatal (
184+ fx. tcx . dcx ( ) . span_fatal (
185185 fx. mir . local_decls [ local] . source_info . span ,
186186 "unsized locals are not yet supported" ,
187187 ) ;
@@ -226,7 +226,7 @@ pub(crate) fn codegen_fn_prelude<'tcx>(fx: &mut FunctionCx<'_, '_, 'tcx>, start_
226226
227227 // FIXME implement variadics in cranelift
228228 if fn_abi. c_variadic {
229- fx. tcx . sess . span_fatal (
229+ fx. tcx . dcx ( ) . span_fatal (
230230 fx. mir . span ,
231231 "Defining variadic functions is not yet supported by Cranelift" ,
232232 ) ;
@@ -543,7 +543,7 @@ pub(crate) fn codegen_terminator_call<'tcx>(
543543 // FIXME find a cleaner way to support varargs
544544 if fn_sig. c_variadic ( ) {
545545 if !matches ! ( fn_sig. abi( ) , Abi :: C { .. } ) {
546- fx. tcx . sess . span_fatal (
546+ fx. tcx . dcx ( ) . span_fatal (
547547 source_info. span ,
548548 format ! ( "Variadic call for non-C abi {:?}" , fn_sig. abi( ) ) ,
549549 ) ;
@@ -555,7 +555,7 @@ pub(crate) fn codegen_terminator_call<'tcx>(
555555 let ty = fx. bcx . func . dfg . value_type ( arg) ;
556556 if !ty. is_int ( ) {
557557 // FIXME set %al to upperbound on float args once floats are supported
558- fx. tcx . sess . span_fatal (
558+ fx. tcx . dcx ( ) . span_fatal (
559559 source_info. span ,
560560 format ! ( "Non int ty {:?} for variadic call" , ty) ,
561561 ) ;
0 commit comments