authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2024-08-25 00:44:35+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2024-09-06 20:11:47+02:00
logaf370a69cd16305e2cd14b584187e84e30bd065f
tree1e5389a9cf60ec1f55bbb2eefbef94b857ccd7f7
parent17f54e827499058e281abeab5d6634bf415c3580
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

std.Target: Make Abi.floatAbi() more accurate.

Also rename Target.getFloatAbi() to floatAbi().

1 files changed, 8 insertions(+), 7 deletions(-)

lib/std/Target.zig+8-7
......@@ -765,12 +765,13 @@ pub const Abi = enum {
765765
766766 pub inline fn floatAbi(abi: Abi) FloatAbi {
767767 return switch (abi) {
768 .gnueabihf,
769 .eabihf,
770 .musleabihf,
771 => .hard,
772 .ohos => .soft,
773 else => .soft,
768 .eabi,
769 .gnueabi,
770 .musleabi,
771 .gnusf,
772 .ohos,
773 => .soft,
774 else => .hard,
774775 };
775776 }
776777};
......@@ -1645,7 +1646,7 @@ pub const FloatAbi = enum {
16451646 soft,
16461647};
16471648
1648pub inline fn getFloatAbi(target: Target) FloatAbi {
1649pub inline fn floatAbi(target: Target) FloatAbi {
16491650 return target.abi.floatAbi();
16501651}
16511652