clang-modernize -use-nullptr

and s/\bNULL\b/nullptr/g for *.cpp/h/mm files not compiled on my machine
This commit is contained in:
Tillmann Karras
2014-03-09 21:14:26 +01:00
parent f28116b7da
commit d802d39281
292 changed files with 1526 additions and 1526 deletions

View File

@ -143,7 +143,7 @@ public:
#ifdef _WIN32
InitializeSRWLock(&m_handle);
#else
pthread_mutex_init(&m_handle, NULL);
pthread_mutex_init(&m_handle, nullptr);
#endif
}
@ -238,7 +238,7 @@ public:
typedef Mutex mutex_type;
unique_lock()
: pm(NULL), owns(false)
: pm(nullptr), owns(false)
{}
/*explicit*/ unique_lock(mutex_type& m)
@ -290,11 +290,11 @@ public:
unique_lock(const unique_lock&) /*= delete*/;
unique_lock(unique_lock&& other)
: pm(NULL), owns(false)
: pm(nullptr), owns(false)
{
#else
unique_lock(const unique_lock& u)
: pm(NULL), owns(false)
: pm(nullptr), owns(false)
{
// ugly const_cast to get around lack of rvalue references
unique_lock& other = const_cast<unique_lock&>(u);
@ -335,7 +335,7 @@ public:
{
auto const ret = mutex();
pm = NULL;
pm = nullptr;
owns = false;
return ret;