| 122 | }; |
| 123 | |
| 124 | FunctionDecl *getFunctionDecl(ASTUnit &AST, std::string FuncName) { |
| 125 | for (auto D : AST.getASTContext().getTranslationUnitDecl()->decls()) { |
| 126 | if (auto clangF = D->getAsFunction()) { |
| 127 | if (clangF->getName() != FuncName) |
| 128 | continue; |
| 129 | return clangF; |
| 130 | } |
| 131 | } |
| 132 | return nullptr; |
| 133 | } |
| 134 | |
| 135 | class TestStripConstExpr : public ::testing::Test { |
| 136 |