[mlir] Fix a warning
This patch fixes: mlir/tools/mlir-tblgen/AttrOrTypeFormatGen.cpp:586:14: error: variable 'realParam' set but not used [-Werror,-Wunused-but-set-variable]
This commit is contained in:
@@ -583,7 +583,7 @@ void DefFormat::genStructParser(StructDirective *el, FmtContext &ctx,
|
||||
for (FormatElement *arg : el->getElements()) {
|
||||
ParameterElement *param = getEncapsulatedParameterElement(arg);
|
||||
os.getStream().printReindented(strfmt(checkParamKey, param->getName()));
|
||||
if (auto realParam = dyn_cast<ParameterElement>(arg))
|
||||
if (isa<ParameterElement>(arg))
|
||||
genVariableParser(param, ctx, os.indent());
|
||||
else if (auto custom = dyn_cast<CustomDirective>(arg))
|
||||
genCustomParser(custom, ctx, os.indent());
|
||||
|
||||
Reference in New Issue
Block a user