Mercurial > hg > svcore
diff base/Debug.cpp @ 1882:38be2fa29efd
We need to be c++11 compatible here, and make_unique isn't in it
author | Chris Cannam |
---|---|
date | Fri, 26 Jun 2020 12:13:13 +0100 |
parents | 166d7a4c2cd6 |
children |
line wrap: on
line diff
--- a/base/Debug.cpp Fri Jun 26 11:45:39 2020 +0100 +++ b/base/Debug.cpp Fri Jun 26 12:13:13 2020 +0100 @@ -32,7 +32,7 @@ SVDebug &getSVDebug() { mutex.lock(); if (!svdebug) { - svdebug = std::make_unique<SVDebug>(); + svdebug = std::unique_ptr<SVDebug>(new SVDebug()); } mutex.unlock(); return *svdebug; @@ -42,9 +42,9 @@ mutex.lock(); if (!svcerr) { if (!svdebug) { - svdebug = std::make_unique<SVDebug>(); + svdebug = std::unique_ptr<SVDebug>(new SVDebug()); } - svcerr = std::make_unique<SVCerr>(*svdebug); + svcerr = std::unique_ptr<SVCerr>(new SVCerr(*svdebug)); } mutex.unlock(); return *svcerr;