I guess in theory, you could pull it off with a very clever allocator. Bloomberg’s BDE has an allocator along those lines ( https://bloomberg.github.io/bde/classbdlma_1_1BufferedSequen... ), but I don’t think it made it into the standard (memory_resource header).
My point is only that runtime-sized arrays may have made it into the C standard, but they aren’t in the C++ standard.
My point is only that runtime-sized arrays may have made it into the C standard, but they aren’t in the C++ standard.