Pacify gcc-4.4.

llvm-svn: 116300
This commit is contained in:
Duncan Sands 2010-10-12 14:07:59 +00:00
parent 73d3618223
commit 38b918c0cf
1 changed files with 4 additions and 2 deletions

View File

@ -7217,8 +7217,10 @@ void Sema::ActOnEnumBody(SourceLocation EnumLoc, SourceLocation LBraceLoc,
if (Enum->isFixed()) {
BestType = BestPromotionType = Enum->getIntegerType();
// We don't set BestWidth, because BestType is going to be the
// type of the enumerators.
// We don't need to set BestWidth, because BestType is going to be the type
// of the enumerators, but we do anyway because otherwise some compilers
// warn that it might be used uninitialized.
BestWidth = CharWidth;
}
else if (NumNegativeBits) {
// If there is a negative value, figure out the smallest integer type (of