File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -40,8 +40,13 @@ static_assert(sizeof(double) == 8, "64-bit double assumed");
40
40
static_assert (sizeof (short ) == 2, "16-bit short assumed");
41
41
static_assert (sizeof (int ) == 4, "32-bit int assumed");
42
42
43
+ // Assumption: We assume size_t to be 32-bit or 64-bit.
44
+ // Example(s): size_t assumed to be at least 32-bit in ecdsa_signature_parse_der_lax(...).
45
+ // size_t assumed to be 32-bit or 64-bit in MallocUsage(...).
46
+ static_assert (sizeof (size_t ) == 4 || sizeof(size_t ) == 8, "size_t assumed to be 32-bit or 64-bit");
47
+ static_assert (sizeof (size_t ) == sizeof(void *), "Sizes of size_t and void* assumed to be equal");
48
+
43
49
// Some important things we are NOT assuming (non-exhaustive list):
44
- // * We are NOT assuming a specific value for sizeof(std::size_t).
45
50
// * We are NOT assuming a specific value for std::endian::native.
46
51
// * We are NOT assuming a specific value for std::locale("").name().
47
52
// * We are NOT assuming a specific value for std::numeric_limits<char>::is_signed.
You can’t perform that action at this time.
0 commit comments