Код: Выделить всё
#include
#include
int main()
{
char static_array[]={1,2,3};
std::span sp{static_array};
if (std::dynamic_extent == sp.extent)
std::cout
Подробнее здесь: [url]https://stackoverflow.com/questions/79241656/why-extent-of-stdspan-created-from-a-static-array-considered-to-have-a-dynamic[/url]
Мобильная версия