@@ -20,7 +20,8 @@ use rustc_span::DUMMY_SP;
2020use rustc_span:: { Span , Symbol } ;
2121use rustc_target:: abi:: call:: { ArgAbi , ArgAttributes , FnAbi , PassMode } ;
2222use rustc_target:: abi:: {
23- Abi , Align , FieldsShape , LayoutS , Primitive , Scalar , Size , TagEncoding , VariantIdx , Variants ,
23+ Abi , Align , FieldsShape , Float , LayoutS , Primitive , Scalar , Size , TagEncoding , VariantIdx ,
24+ Variants ,
2425} ;
2526use rustc_target:: spec:: abi:: Abi as SpecAbi ;
2627use std:: cell:: RefCell ;
@@ -504,10 +505,10 @@ fn trans_scalar<'tcx>(
504505 Primitive :: Int ( width, signedness) => {
505506 SpirvType :: Integer ( width. size ( ) . bits ( ) as u32 , signedness) . def ( span, cx)
506507 }
507- Primitive :: F16 => SpirvType :: Float ( 16 ) . def ( span, cx) ,
508- Primitive :: F32 => SpirvType :: Float ( 32 ) . def ( span, cx) ,
509- Primitive :: F64 => SpirvType :: Float ( 64 ) . def ( span, cx) ,
510- Primitive :: F128 => SpirvType :: Float ( 128 ) . def ( span, cx) ,
508+ Primitive :: Float ( Float :: F16 ) => SpirvType :: Float ( 16 ) . def ( span, cx) ,
509+ Primitive :: Float ( Float :: F32 ) => SpirvType :: Float ( 32 ) . def ( span, cx) ,
510+ Primitive :: Float ( Float :: F64 ) => SpirvType :: Float ( 64 ) . def ( span, cx) ,
511+ Primitive :: Float ( Float :: F128 ) => SpirvType :: Float ( 128 ) . def ( span, cx) ,
511512 Primitive :: Pointer ( _) => {
512513 let pointee_ty = dig_scalar_pointee ( cx, ty, offset) ;
513514 // Pointers can be recursive. So, record what we're currently translating, and if we're already translating
0 commit comments