Created on 2019-02-20.00:00:00 last changed 45 months ago
Proposed resolution:
This wording is relative to N4800.
Change [allocator.members] as indicated:
[[nodiscard]] T* allocate(size_t n);[…]
-4- Throws: bad_array_new_length if SIZE_MAX / sizeof(T) < n, or bad_alloc if the storage cannot be obtained.
[ 2019 Cologne Wednesday night ]
Status to Ready; will open additional issue to reconcile this and 3038
[ 2019-03-05 Priority set to 3 after reflector discussion ]
[allocator.members]/2 says:
-2- Returns: A pointer to the initial element of an array of storage of size n * sizeof(T), aligned appropriately for objects of type T.
As in LWG 3038, we should not return too little storage for n objects of size sizeof(T), e.g. when n is SIZE_MAX / 2 and T is short.
History | |||
---|---|---|---|
Date | User | Action | Args |
2021-02-25 10:48:01 | admin | set | status: wp -> c++20 |
2019-11-19 14:48:30 | admin | set | status: voting -> wp |
2019-10-07 02:48:00 | admin | set | status: ready -> voting |
2019-07-22 17:12:46 | admin | set | messages: + msg10493 |
2019-07-22 17:12:46 | admin | set | status: new -> ready |
2019-03-05 18:54:44 | admin | set | messages: + msg10342 |
2019-03-03 18:40:22 | admin | set | messages: + msg10333 |
2019-02-20 00:00:00 | admin | create |