mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-11 23:05:31 +00:00
Initialize the components of this class. Otherwise GCC thinks that Array may be
used uninitialized, since it fails to understand that Array is only used when SingleValue is not, and outputs a warning. It also seems generally safer given that the constructor is non-trivial and has plenty of early exits. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173242 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
023d97d703
commit
70465616c2
@ -3382,7 +3382,8 @@ SwitchLookupTable::SwitchLookupTable(Module &M,
|
||||
ConstantInt *Offset,
|
||||
const SmallVector<std::pair<ConstantInt*, Constant*>, 4>& Values,
|
||||
Constant *DefaultValue,
|
||||
const DataLayout *TD) {
|
||||
const DataLayout *TD)
|
||||
: SingleValue(0), BitMap(0), BitMapElementTy(0), Array(0) {
|
||||
assert(Values.size() && "Can't build lookup table without values!");
|
||||
assert(TableSize >= Values.size() && "Can't fit values in table!");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user