[Lldb-commits] [lldb] r229843 - Silence unused variable warnings in release builds
Pavel Labath
labath at google.com
Thu Feb 19 03:41:12 PST 2015
Author: labath
Date: Thu Feb 19 05:41:12 2015
New Revision: 229843
URL: http://llvm.org/viewvc/llvm-project?rev=229843&view=rev
Log:
Silence unused variable warnings in release builds
Modified:
lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp
Modified: lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp?rev=229843&r1=229842&r2=229843&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp (original)
+++ lldb/trunk/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp Thu Feb 19 05:41:12 2015
@@ -710,6 +710,7 @@ DynamicLoaderMacOSXDYLD::ReadAllImageInf
const size_t count_v13 = count_v11 +
addr_size + // sharedCacheSlide
sizeof (uuid_t); // sharedCacheUUID
+ (void) count_v13; // Avoid warnings when assertions are off.
assert (sizeof (buf) >= count_v13);
Error error;
Modified: lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp?rev=229843&r1=229842&r2=229843&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp (original)
+++ lldb/trunk/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp Thu Feb 19 05:41:12 2015
@@ -44,6 +44,7 @@ AppleObjCTypeEncodingParser::ReadQuotedS
while (type.HasAtLeast(1) && type.Peek() != '"')
buffer.Printf("%c",type.Next());
StringLexer::Character next = type.Next();
+ (void) next; // Avoid warnings when assertions are off.
assert (next == '"');
return buffer.GetString();
}
More information about the lldb-commits
mailing list