Fix opt build where compiled out assert leaves unused local variable.

PiperOrigin-RevId: 211631896
This commit is contained in:
MLIR Team 2018-09-05 07:38:20 -07:00 committed by jpienaar
parent 95f31d53d5
commit f884e8da82
1 changed files with 2 additions and 3 deletions

View File

@ -38,9 +38,8 @@ static AffineExpr *toAffineExpr(ArrayRef<int64_t> eq, unsigned numDims,
unsigned numSymbols,
ArrayRef<AffineExpr *> localExprs,
MLIRContext *context) {
unsigned numLocals = eq.size() - numDims - numSymbols - 1;
assert(numLocals == localExprs.size() &&
// Assert expected numLocals = eq.size() - numDims - numSymbols - 1
assert(eq.size() - numDims - numSymbols - 1 == localExprs.size() &&
"unexpected number of local expressions");
AffineExpr *expr = AffineConstantExpr::get(0, context);