First use of shared_ptr, yay! Former-commit-id: 4c22341fba5674746d5299cf0e8dbf6dc31d5362
Former-commit-id: 1811304cd0efe9a86cbae83faaf4c39d9fae248f