Skip to content

Commit 64dd8ca

Browse files
Firestar99eddyb
authored andcommitted
update rspirv: fix clippy lints
1 parent b10143c commit 64dd8ca

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

crates/rustc_codegen_spirv/src/builder/spirv_asm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1439,7 +1439,7 @@ impl<'cx, 'tcx> Builder<'cx, 'tcx> {
14391439
Ok(x) => inst.operands.push(dr::Operand::StoreCacheControl(x)),
14401440
Err(()) => self.err(format!("unknown StoreCacheControl {word}")),
14411441
},
1442-
(OperandKind::LiteralFloat, Some(word)) => todo!(),
1442+
(OperandKind::LiteralFloat, Some(_word)) => todo!(),
14431443
(kind, None) => match token {
14441444
Token::Word(_) => bug!(),
14451445
Token::String(_) => {

crates/rustc_codegen_spirv/src/builder_spirv.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -583,10 +583,8 @@ impl<'tcx> BuilderSpirv<'tcx> {
583583
}
584584
let val = val_with_type.val;
585585
let id = match val {
586-
SpirvConst::U32(v) => builder.constant_bit32(ty, v),
587-
SpirvConst::U64(v) => builder.constant_bit64(ty, v),
588-
SpirvConst::F32(v) => builder.constant_bit32(ty, v),
589-
SpirvConst::F64(v) => builder.constant_bit64(ty, v),
586+
SpirvConst::U32(v) | SpirvConst::F32(v) => builder.constant_bit32(ty, v),
587+
SpirvConst::U64(v) | SpirvConst::F64(v) => builder.constant_bit64(ty, v),
590588
SpirvConst::Bool(v) => {
591589
if v {
592590
builder.constant_true(ty)

0 commit comments

Comments
 (0)