Define DieInCRTDebugElse12() inside #ifdef _DEBUG
DieInCRTDebugElse12() is only used inside a #ifdef _DEBUG block. Put its definition inside a #ifdef _DEBUG block, too, otherwise we get a "defined but not used [-Wunused-function]" warning under MinGW GCC. PiperOrigin-RevId: 891795658 Change-Id: Ic9109eebc354dd20b2a5430794f491c9b451931f
This commit is contained in:
committed by
Copybara-Service
parent
2461743991
commit
5fddfab2d2
@@ -208,6 +208,7 @@ int DieInDebugElse12(int* sideeffect) {
|
||||
#ifdef GTEST_OS_WINDOWS
|
||||
|
||||
// Death in dbg due to Windows CRT assertion failure, not opt.
|
||||
#ifdef _DEBUG
|
||||
int DieInCRTDebugElse12(int* sideeffect) {
|
||||
if (sideeffect) *sideeffect = 12;
|
||||
|
||||
@@ -222,6 +223,7 @@ int DieInCRTDebugElse12(int* sideeffect) {
|
||||
|
||||
return 12;
|
||||
}
|
||||
#endif // _DEBUG
|
||||
|
||||
#endif // GTEST_OS_WINDOWS
|
||||
|
||||
|
||||
Reference in New Issue
Block a user