mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-02 13:01:27 +12:00
Correct get_int_t to get_uint_t.
Add get_sint_t.
This commit is contained in:
parent
997e3046e3
commit
ec2db8edbc
3 changed files with 39 additions and 32 deletions
|
@ -412,10 +412,10 @@ std::size_t cfmt_append(Dst& out, const Char* fmt, Src&& src)
|
|||
}
|
||||
|
||||
const u64 mask =
|
||||
ctx.type == 1 ? u64{std::numeric_limits<get_int_t<1>>::max()} :
|
||||
ctx.type == 2 ? u64{std::numeric_limits<get_int_t<2>>::max()} :
|
||||
ctx.type == 4 ? u64{std::numeric_limits<get_int_t<4>>::max()} :
|
||||
u64{std::numeric_limits<get_int_t<8>>::max()};
|
||||
ctx.type == 1 ? 0xff :
|
||||
ctx.type == 2 ? 0xffff :
|
||||
ctx.type == 4 ? 0xffff'ffffu :
|
||||
0xffff'ffff'ffff'ffffu;
|
||||
|
||||
// Trunc sign-extended signed types
|
||||
const u64 val = src.template get<u64>(ctx.args) & mask;
|
||||
|
@ -469,10 +469,10 @@ std::size_t cfmt_append(Dst& out, const Char* fmt, Src&& src)
|
|||
}
|
||||
|
||||
const u64 mask =
|
||||
ctx.type == 1 ? u64{std::numeric_limits<get_int_t<1>>::max()} :
|
||||
ctx.type == 2 ? u64{std::numeric_limits<get_int_t<2>>::max()} :
|
||||
ctx.type == 4 ? u64{std::numeric_limits<get_int_t<4>>::max()} :
|
||||
u64{std::numeric_limits<get_int_t<8>>::max()};
|
||||
ctx.type == 1 ? 0xff :
|
||||
ctx.type == 2 ? 0xffff :
|
||||
ctx.type == 4 ? 0xffff'ffffu :
|
||||
0xffff'ffff'ffff'ffffu;
|
||||
|
||||
// Trunc sign-extended signed types
|
||||
const u64 val = src.template get<u64>(ctx.args) & mask;
|
||||
|
@ -533,10 +533,10 @@ std::size_t cfmt_append(Dst& out, const Char* fmt, Src&& src)
|
|||
}
|
||||
|
||||
const u64 mask =
|
||||
ctx.type == 1 ? u64{std::numeric_limits<get_int_t<1>>::max()} :
|
||||
ctx.type == 2 ? u64{std::numeric_limits<get_int_t<2>>::max()} :
|
||||
ctx.type == 4 ? u64{std::numeric_limits<get_int_t<4>>::max()} :
|
||||
u64{std::numeric_limits<get_int_t<8>>::max()};
|
||||
ctx.type == 1 ? 0xff :
|
||||
ctx.type == 2 ? 0xffff :
|
||||
ctx.type == 4 ? 0xffff'ffffu :
|
||||
0xffff'ffff'ffff'ffffu;
|
||||
|
||||
// Trunc sign-extended signed types
|
||||
const u64 val = src.template get<u64>(ctx.args) & mask;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue