std::unique_ptr<int[]> p(new int[10]); //ok
std::shared_ptr<int[]> p(new int[10]); //Error
shared_ptr<int> sp( new int[10],[](int *p){delete [] p;});
//Ok, writing custom deleter for
//array since shared_ptr will call
//delete by default.
Is there any specific reason shared_ptr signature is different for arrays when compared to unique_ptr?
It would have been simpler if both api followed similar signature.