File tree 3 files changed +7
-16
lines changed
compiler/rustc_ty_utils/src
3 files changed +7
-16
lines changed Original file line number Diff line number Diff line change @@ -436,10 +436,7 @@ fn fn_abi_sanity_check<'tcx>(
436
436
) {
437
437
let tcx = cx. tcx ( ) ;
438
438
439
- if spec_abi == ExternAbi :: Rust
440
- || spec_abi == ExternAbi :: RustCall
441
- || spec_abi == ExternAbi :: RustCold
442
- {
439
+ if spec_abi. is_rustic_abi ( ) {
443
440
if arg. layout . is_zst ( ) {
444
441
// Casting closures to function pointers depends on ZST closure types being
445
442
// omitted entirely in the calling convention.
@@ -687,7 +684,7 @@ fn fn_abi_adjust_for_abi<'tcx>(
687
684
688
685
let tcx = cx. tcx ( ) ;
689
686
690
- if abi == ExternAbi :: Rust || abi == ExternAbi :: RustCall || abi == ExternAbi :: RustIntrinsic {
687
+ if abi. is_rustic_abi ( ) {
691
688
fn_abi. adjust_for_rust_abi ( cx, abi) ;
692
689
693
690
// Look up the deduced parameter attributes for this function, if we have its def ID and
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ //@compile-flags: -Clink-dead-code=true --crate-type lib
2
+ // We used to not handle all "rustic" ABIs in a (relatively) uniform way,
3
+ // so we failed to fix up arguments for actually passing through the ABI...
4
+ #![ feature( rust_cold_cc) ]
5
+ pub extern "rust-cold" fn foo ( _: [ usize ; 3 ] ) { }
You can’t perform that action at this time.
0 commit comments