Nowadays the C++ standard removes need for unnecessary checks.
Not nowadays, but since more than one and a half decade. C++ was standardized in 1998.
I only keep these template functions around for DX programming because from what I can tell, it is not safe to use C++11 smart pointers due to reference counting issues
Written in such a general way, that's wrong. I don't see a problem with reference counting, and not all smart pointers use it anyway.
std::unique_ptr is a simple pointer wrapper that is just as fast as performing manual
new/
delete, and it's faster and much safer than your
SafeDelete() function.
"Safe delete" is an abomination which inspired a lot of C++ developers to write questionable code, and unfortunately it has survived a long time, even though the original problems have disappeared long ago. One could even call it an anti-idiom; there's absolutely no sane reason to use it. This has nothing to do with C++11, smart pointers and RAII have been around for much longer (
boost::scoped_ptr,
std::auto_ptr). Even if those are not ideal nowadays and
std::unique_ptr should be preferred, they're still much better than any way of managing memory or other resources manually.
If you're interested, read the
RAII thread, we all tried to explain why RAII is such a powerful idiom that should be applied wherever possible.