Skip to content

Commit

Permalink
fix for llvm 13
Browse files Browse the repository at this point in the history
  • Loading branch information
terminaldweller committed Jul 14, 2021
1 parent e447e32 commit 308bc02
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cgrep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1106,15 +1106,15 @@ class CgrepFrontendAction : public ASTFrontendAction {
/*Main*/
int main(int argc, const char **argv) {
#if __clang_major__ >= 13
auto op =
CommonOptionsParser::create(argc, argv, CGrepCat);
auto op = CommonOptionsParser::create(argc, argv, CGrepCat);
if (auto error = op.takeError()) {
errs() << toString(std::move(error)) << "\n";
return 1;
}
ClangTool Tool(op->getCompilations(), op->getSourcePathList());
#else
CommonOptionsParser op(argc, argv, CGrepCat);
ClangTool Tool(op.getCompilations(), op.getSourcePathList());
#endif
int ret = 0;

Expand Down

0 comments on commit 308bc02

Please sign in to comment.