Код: Выделить всё
std::unique_ptr ptr_obj=new int{10};
Этот код работает нормально:
Код: Выделить всё
std::unique_ptr ptr_obj{new int{10}};
Подробнее здесь: https://stackoverflow.com/questions/784 ... -pointer-c
Код: Выделить всё
std::unique_ptr ptr_obj=new int{10};
Код: Выделить всё
std::unique_ptr ptr_obj{new int{10}};