From 0fa1ee8f1c311a7740238d226e4a697708b5c338 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Mon, 6 Mar 2023 19:28:35 -0800 Subject: [PATCH] [DebugInfo] Fix a warning This patch fixes: llvm/lib/DebugInfo/GSYM/GsymCreator.cpp:117:18: error: unused variable 'MaxAddressOffset' [-Werror,-Wunused-variable] --- llvm/lib/DebugInfo/GSYM/GsymCreator.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/llvm/lib/DebugInfo/GSYM/GsymCreator.cpp b/llvm/lib/DebugInfo/GSYM/GsymCreator.cpp index 991c609b25706..60b6dbc6a12d2 100644 --- a/llvm/lib/DebugInfo/GSYM/GsymCreator.cpp +++ b/llvm/lib/DebugInfo/GSYM/GsymCreator.cpp @@ -124,6 +124,7 @@ llvm::Error GsymCreator::encode(FileWriter &O) const { // introduced when the code changes that can cause problems here so it is // good to catch this during testing. assert(AddrOffset <= MaxAddressOffset); + (void)MaxAddressOffset; switch (Hdr.AddrOffSize) { case 1: O.writeU8(static_cast(AddrOffset));