Instantly share code, notes, and snippets.

Embed
What would you like to do?
#include <memory>
int main() {
// bounded array
std::shared_ptr<int[5]> ptr1 { new int[5]{} };
// un-bounded array
std::shared_ptr<int[]> ptr2 { new int[5]{} };
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment