false when the product overflows size_t, true otherwise.bool checkedByteCount(size_t count, size_t elementSize, out size_t bytes) @safe pure nothrow @nogcAn overflow-checked count * elementSize.
The one typed helper this module ships; typed allocation belongs with the typed owners that use it.
count | number of elements. |
elementSize | size of one element in bytes; 0 yields 0 bytes. |
bytes | receives count * elementSize, or 0 on overflow. |
false when the product overflows size_t, true otherwise.