mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-20 16:28:54 +00:00
AK: Mark HashTable::size_in_bytes() as constexpr
This commit is contained in:
parent
1aa527f5b6
commit
93cf01ad7d
Notes:
sideshowbarker
2024-07-18 04:20:34 +09:00
Author: https://github.com/Hendiadyoin1
Commit: 93cf01ad7d
Pull-request: https://github.com/SerenityOS/serenity/pull/9405
Reviewed-by: https://github.com/Dexesttp
Reviewed-by: https://github.com/sin-ack ✅
1 changed files with 1 additions and 1 deletions
|
@ -378,7 +378,7 @@ private:
|
|||
}
|
||||
}
|
||||
|
||||
[[nodiscard]] static size_t size_in_bytes(size_t capacity)
|
||||
[[nodiscard]] static constexpr size_t size_in_bytes(size_t capacity)
|
||||
{
|
||||
if constexpr (IsOrdered) {
|
||||
return sizeof(BucketType) * capacity;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue