mirror of
https://github.com/SerenityOS/serenity
synced 2024-10-15 04:13:11 +00:00
AK: Rearrange Error's members to reduce its size by 8 bytes
This shrinks sizeof(Error) from 32 bytes to 24 bytes, which in turn will shrink sizeof(ErrorOr<T>) by the same amount (in cases where sizeof(T) is less than sizeof(Error)).
This commit is contained in:
parent
74de1f6193
commit
4b4b15adb1
|
@ -68,14 +68,14 @@ private:
|
|||
}
|
||||
|
||||
Error(StringView syscall_name, int rc)
|
||||
: m_code(-rc)
|
||||
, m_string_literal(syscall_name)
|
||||
: m_string_literal(syscall_name)
|
||||
, m_code(-rc)
|
||||
, m_syscall(true)
|
||||
{
|
||||
}
|
||||
|
||||
int m_code { 0 };
|
||||
StringView m_string_literal;
|
||||
int m_code { 0 };
|
||||
bool m_syscall { false };
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue