Skip to content
This repository has been archived by the owner on Jan 1, 2023. It is now read-only.

Commit

Permalink
[globalisel] Fix an unused variable warning when NDEBUG is defined.
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@292653 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
dsandersllvm committed Jan 20, 2017
1 parent 4176db8 commit 57176dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/TableGen/RegisterBankEmitter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,8 @@ void RegisterBankEmitter::emitBaseClassImplementation(
<< " : RegisterBankInfo(RegBanks, " << TargetName
<< "::NumRegisterBanks) {\n"
<< " // Assert that RegBank indices match their ID's\n"
<< " unsigned Index = 0;\n"
<< "#ifndef NDEBUG\n"
<< " unsigned Index = 0;\n"
<< " for (const auto &RB : RegBanks)\n"
<< " assert(Index++ == RB->getID() && \"Index != ID\");\n"
<< "#endif // NDEBUG\n"
Expand Down

0 comments on commit 57176dc

Please sign in to comment.