@@ -3201,7 +3201,7 @@ static bool ValidLookupTableConstant(Constant *C) {
3201
3201
}
3202
3202
3203
3203
// / LookupConstant - If V is a Constant, return it. Otherwise, try to look up
3204
- // / its constant value in ConstantPool, returning NULL if it's not there.
3204
+ // / its constant value in ConstantPool, returning 0 if it's not there.
3205
3205
static Constant *LookupConstant (Value *V,
3206
3206
const SmallDenseMap<Value*, Constant*>& ConstantPool) {
3207
3207
if (Constant *C = dyn_cast<Constant>(V))
@@ -3212,7 +3212,7 @@ static Constant *LookupConstant(Value *V,
3212
3212
// / ConstantFold - Try to fold instruction I into a constant. This works for
3213
3213
// / simple instructions such as binary operations where both operands are
3214
3214
// / constant or can be replaced by constants from the ConstantPool. Returns the
3215
- // / resulting constant on success, NULL otherwise.
3215
+ // / resulting constant on success, 0 otherwise.
3216
3216
static Constant *ConstantFold (Instruction *I,
3217
3217
const SmallDenseMap<Value*, Constant*>& ConstantPool) {
3218
3218
if (BinaryOperator *BO = dyn_cast<BinaryOperator>(I)) {
@@ -3243,6 +3243,7 @@ static Constant *ConstantFold(Instruction *I,
3243
3243
return LookupConstant (Select->getTrueValue (), ConstantPool);
3244
3244
if (A->isNullValue ())
3245
3245
return LookupConstant (Select->getFalseValue (), ConstantPool);
3246
+ return 0 ;
3246
3247
}
3247
3248
3248
3249
if (CastInst *Cast = dyn_cast<CastInst>(I)) {
@@ -3257,7 +3258,7 @@ static Constant *ConstantFold(Instruction *I,
3257
3258
3258
3259
// / GetCaseResults - Try to determine the resulting constant values in phi nodes
3259
3260
// / at the common destination basic block, *CommonDest, for one of the case
3260
- // / destionations CaseDest corresponding to value CaseVal (NULL for the default
3261
+ // / destionations CaseDest corresponding to value CaseVal (0 for the default
3261
3262
// / case), of a switch instruction SI.
3262
3263
static bool GetCaseResults (SwitchInst *SI,
3263
3264
ConstantInt *CaseVal,
0 commit comments