diff --git a/mlir/lib/Dialect/SPIRV/SPIRVLowering.cpp b/mlir/lib/Dialect/SPIRV/SPIRVLowering.cpp --- a/mlir/lib/Dialect/SPIRV/SPIRVLowering.cpp +++ b/mlir/lib/Dialect/SPIRV/SPIRVLowering.cpp @@ -318,4 +318,4 @@ } return true; -}; +} diff --git a/mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp b/mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp --- a/mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp +++ b/mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp @@ -1305,7 +1305,7 @@ continue; os << " case Capability::" << enumerant.getSymbol() - << ": {static Capability implies[] = {"; + << ": {static const Capability implies[] = {"; std::vector impliedCapsDefs = def.getValueAsListOfDefs("implies"); mlir::interleaveComma(impliedCapsDefs, os, [&](const Record *capDef) { os << "Capability::" << EnumAttrCase(capDef).getSymbol();