mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 10:48:41 +00:00
This doesn't matter per se as the value is immediately validated to be in the 0 to 2^32 - 1 range, but it avoids having to cast a number that potentially doesn't fit into a size_t into one at the call site. More often than not, array-like lengths are only validated to be <= 2^52 - 1, i.e. MAX_SAFE_INTEGER. This is fully backwards compatible with existing code as a size_t always fits into an u64, but an u64 might not always fit into a size_t.
14 KiB
14 KiB