Skip to content

Commit

Permalink
update rspirv: fix clippy lints
Browse files Browse the repository at this point in the history
  • Loading branch information
Firestar99 committed Jan 23, 2024
1 parent 2a3dbcb commit 19b955b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion crates/rustc_codegen_spirv/src/builder/spirv_asm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1412,7 +1412,7 @@ impl<'cx, 'tcx> Builder<'cx, 'tcx> {
Ok(x) => inst.operands.push(dr::Operand::StoreCacheControl(x)),
Err(()) => self.err(format!("unknown StoreCacheControl {word}")),
},
(OperandKind::LiteralFloat, Some(word)) => todo!(),
(OperandKind::LiteralFloat, Some(_word)) => todo!(),
(kind, None) => match token {
Token::Word(_) => bug!(),
Token::String(_) => {
Expand Down
6 changes: 2 additions & 4 deletions crates/rustc_codegen_spirv/src/builder_spirv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -583,10 +583,8 @@ impl<'tcx> BuilderSpirv<'tcx> {
}
let val = val_with_type.val;
let id = match val {
SpirvConst::U32(v) => builder.constant_bit32(ty, v),
SpirvConst::U64(v) => builder.constant_bit64(ty, v),
SpirvConst::F32(v) => builder.constant_bit32(ty, v),
SpirvConst::F64(v) => builder.constant_bit64(ty, v),
SpirvConst::U32(v) | SpirvConst::F32(v) => builder.constant_bit32(ty, v),
SpirvConst::U64(v) | SpirvConst::F64(v) => builder.constant_bit64(ty, v),
SpirvConst::Bool(v) => {
if v {
builder.constant_true(ty)
Expand Down

0 comments on commit 19b955b

Please sign in to comment.