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

Also rename Target.getFloatAbi() to floatAbi().
This commit is contained in:
Alex Rønne Petersen 2024-08-25 00:44:35 +02:00
parent 17f54e8274
commit af370a69cd
No known key found for this signature in database

View File

@ -765,12 +765,13 @@ pub const Abi = enum {
pub inline fn floatAbi(abi: Abi) FloatAbi {
return switch (abi) {
.gnueabihf,
.eabihf,
.musleabihf,
=> .hard,
.ohos => .soft,
else => .soft,
.eabi,
.gnueabi,
.musleabi,
.gnusf,
.ohos,
=> .soft,
else => .hard,
};
}
};
@ -1645,7 +1646,7 @@ pub const FloatAbi = enum {
soft,
};
pub inline fn getFloatAbi(target: Target) FloatAbi {
pub inline fn floatAbi(target: Target) FloatAbi {
return target.abi.floatAbi();
}