about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2022-08-25 19:18:01 +1000
committerAntoni Boucher <bouanto@zoho.com>2023-02-28 18:57:14 -0500
commit8ebade29d6f45e51b8f72d410a04edd2a25d5bf8 (patch)
tree8d1ad660be76a7500e2f02acdcb0dfd09279a66c
parent3c2d43265c1691647a9e2adc57c7239a4366a624 (diff)
downloadrust-8ebade29d6f45e51b8f72d410a04edd2a25d5bf8.tar.gz
rust-8ebade29d6f45e51b8f72d410a04edd2a25d5bf8.zip
Turn `ArgAbi::pad` into a `bool`.
Because it's only ever set to `None` or `Some(Reg::i32())`.
-rw-r--r--src/abi.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/abi.rs b/src/abi.rs
index 87b730d29cd..3186b363e35 100644
--- a/src/abi.rs
+++ b/src/abi.rs
@@ -126,8 +126,8 @@ impl<'gcc, 'tcx> FnAbiGccExt<'gcc, 'tcx> for FnAbi<'tcx, Ty<'tcx>> {
 
         for arg in self.args.iter() {
             // add padding
-            if let Some(ty) = arg.pad {
-                argument_tys.push(ty.gcc_type(cx));
+            if arg.pad_i32 {
+                argument_tys.push(Reg::i32().gcc_type(cx));
             }
 
             let arg_ty = match arg.mode {