forked from OSchip/llvm-project
Cleanup comparisons to VariableArrayType::Static for non-VLAs
The enum is part of ArrayType, so there is no functional change, but comparing to ArrayType::Static for non-VLAs makes more sense. llvm-svn: 213446
This commit is contained in:
parent
bfe2d3c0f9
commit
16e394a36c
|
@ -436,7 +436,7 @@ void TypePrinter::printConstantArrayAfter(const ConstantArrayType *T,
|
|||
OS << ' ';
|
||||
}
|
||||
|
||||
if (T->getSizeModifier() == VariableArrayType::Static)
|
||||
if (T->getSizeModifier() == ArrayType::Static)
|
||||
OS << "static ";
|
||||
|
||||
OS << T->getSize().getZExtValue() << ']';
|
||||
|
|
|
@ -1500,7 +1500,7 @@ void CodeGenFunction::EmitFunctionProlog(const CGFunctionInfo &FI,
|
|||
// indicates dereferenceability, and if the size is constant we can
|
||||
// use the dereferenceable attribute (which requires the size in
|
||||
// bytes).
|
||||
if (ArrTy->getSizeModifier() == VariableArrayType::Static) {
|
||||
if (ArrTy->getSizeModifier() == ArrayType::Static) {
|
||||
QualType ETy = ArrTy->getElementType();
|
||||
uint64_t ArrSize = ArrTy->getSize().getZExtValue();
|
||||
if (!ETy->isIncompleteType() && ETy->isConstantSizeType() &&
|
||||
|
|
Loading…
Reference in New Issue