forked from OSchip/llvm-project
Make ASTUnit structure stable with NDEBUG
ASTUnit instances are allocated infrequently so it's fine to keep this field around in all build configurations. Assigns null to silence -Wunused-private-field in Release. llvm-svn: 195419
This commit is contained in:
parent
298c3403d2
commit
b159c13d11
|
@ -406,9 +406,7 @@ private:
|
|||
/// just about any usage.
|
||||
/// Becomes a noop in release mode; only useful for debug mode checking.
|
||||
class ConcurrencyState {
|
||||
#ifndef NDEBUG
|
||||
void *Mutex; // a llvm::sys::MutexImpl in debug;
|
||||
#endif
|
||||
|
||||
public:
|
||||
ConcurrencyState();
|
||||
|
|
|
@ -2953,7 +2953,7 @@ void ASTUnit::ConcurrencyState::finish() {
|
|||
|
||||
#else // NDEBUG
|
||||
|
||||
ASTUnit::ConcurrencyState::ConcurrencyState() {}
|
||||
ASTUnit::ConcurrencyState::ConcurrencyState() { Mutex = 0; }
|
||||
ASTUnit::ConcurrencyState::~ConcurrencyState() {}
|
||||
void ASTUnit::ConcurrencyState::start() {}
|
||||
void ASTUnit::ConcurrencyState::finish() {}
|
||||
|
|
Loading…
Reference in New Issue