diff --git a/polygeist/tools/cgeist/driver.cc b/polygeist/tools/cgeist/driver.cc index 151a48f86cd11..a900fa116cc56 100644 --- a/polygeist/tools/cgeist/driver.cc +++ b/polygeist/tools/cgeist/driver.cc @@ -664,31 +664,29 @@ int main(int argc, char **argv) { std::vector files; std::vector commands; - { - cl::list inputFileName(cl::Positional, cl::OneOrMore, - cl::desc(""), - cl::cat(toolOptions)); - - cl::list inputCommandArgs( - "args", cl::Positional, cl::desc(""), cl::ZeroOrMore, - cl::PositionalEatsArgs); - - int size = MLIRArgs.size(); - const char **data = MLIRArgs.data(); - InitLLVM y(size, data); - cl::ParseCommandLineOptions(size, data); - assert(inputFileName.size()); - for (auto inp : inputFileName) { - std::ifstream inputFile(inp); - if (!inputFile.good()) { - outs() << "Not able to open file: " << inp << "\n"; - return -1; - } - files.push_back(inp); - } - for (auto &cmd : inputCommandArgs) { - commands.push_back(cmd); + cl::list inputFileName(cl::Positional, cl::OneOrMore, + cl::desc(""), + cl::cat(toolOptions)); + + cl::list inputCommandArgs( + "args", cl::Positional, cl::desc(""), cl::ZeroOrMore, + cl::PositionalEatsArgs); + + int size = MLIRArgs.size(); + const char **data = MLIRArgs.data(); + InitLLVM y(size, data); + cl::ParseCommandLineOptions(size, data); + assert(inputFileName.size()); + for (auto inp : inputFileName) { + std::ifstream inputFile(inp); + if (!inputFile.good()) { + outs() << "Not able to open file: " << inp << "\n"; + return -1; } + files.push_back(inp); + } + for (auto &cmd : inputCommandArgs) { + commands.push_back(cmd); } // Register and load MLIR Dialects.