Smart pointers

Why not use smart pointers instead of delete in Haiku? It should prevent all memory leaks, dangling pointers and object ownership problems. When the last reference to an object goes out of scope the object would be deleted automatically.

If the standard C++ auto_ptr isn’t enough there is always Loki and Boostlib.