[HN Gopher] What's so hard about constexpr allocation?
___________________________________________________________________
What's so hard about constexpr allocation?
Author : signa11
Score : 36 points
Date : 2024-07-25 13:13 UTC (9 hours ago)
(HTM) web link (brevzin.github.io)
(TXT) w3m dump (brevzin.github.io)
| jjmarr wrote:
| My current solution to std::vectors not being constexpr is
| initializing a std::array with an immediately invoked lambda
| expression. That lets me algorithmically determine the size of
| the array at compile-time, which is the main use I've wanted out
| of a constexpr std::vector.
___________________________________________________________________
(page generated 2024-07-25 23:06 UTC)