mirror of
https://gitee.com/openharmony/third_party_benchmark
synced 2024-11-23 15:30:48 +00:00
Merge pull request #136 from efcs/remove-check
Remove std::is_trivially_destructible assertion. Fix issue #134.
This commit is contained in:
commit
cf40a0f117
@ -31,7 +31,6 @@
|
||||
#include <atomic>
|
||||
#include <chrono>
|
||||
#include <limits>
|
||||
#include <type_traits>
|
||||
|
||||
#include "arraysize.h"
|
||||
#include "check.h"
|
||||
@ -70,13 +69,8 @@ public:
|
||||
WallTime Now();
|
||||
|
||||
static WallTimeImp& GetWallTimeImp() {
|
||||
static WallTimeImp imp;
|
||||
#if __cplusplus >= 201103L
|
||||
static_assert(std::is_trivially_destructible<WallTimeImp>::value,
|
||||
"WallTimeImp must be trivially destructible to prevent "
|
||||
"issues with static destruction");
|
||||
#endif
|
||||
return imp;
|
||||
static WallTimeImp* imp = new WallTimeImp();
|
||||
return *imp;
|
||||
}
|
||||
|
||||
private:
|
||||
|
Loading…
Reference in New Issue
Block a user