By default std::unique_ptr calls the operator function of structure std::default_delete that just executes operator delete.
So each operator function of the structure std::default_delete recursively calls itself for data member next of structure node.
As result you get the stack overflow.
You would get the same result if you used ordinary pointers instead of the pointers of type std::unique_ptr but added a destructor to the structure node the following way
struct node {
node* next;
int v;
~node() { delete next; }
};
Or even like
struct node {
node* next;
int v;
~node() { if ( next ) delete next; }
};
for a list with a big number of nodes because the destructor will be called recursively