mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 00:07:35 +00:00
AK: Add support for 64-bit size_t
This commit is contained in:
parent
ce56770875
commit
dc93ed4368
4 changed files with 18 additions and 13 deletions
|
@ -234,13 +234,16 @@ public:
|
|||
static String number(u64);
|
||||
static String number(u32);
|
||||
static String number(i32);
|
||||
static String number(i64);
|
||||
|
||||
#ifdef __serenity__
|
||||
static String number(size_t n)
|
||||
{
|
||||
return number((u32)n);
|
||||
if constexpr(sizeof(size_t) == 4)
|
||||
return number((u32)n);
|
||||
else if constexpr(sizeof(size_t) == 8)
|
||||
return number((u64)n);
|
||||
ASSERT_NOT_REACHED();
|
||||
}
|
||||
#endif
|
||||
|
||||
StringView view() const
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue