MCPcopy Create free account
hub / github.com/Samsung/UTopia / findCXXMethodDeclFromCXXRecordDecls

Function findCXXMethodDeclFromCXXRecordDecls

lib/utils/ASTUtil.cpp:173–184  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

171}
172
173std::vector<clang::CXXMethodDecl *> findCXXMethodDeclFromCXXRecordDecls(
174 const clang::CXXRecordDecl *CurCXXRecordDecl, std::string MethodName) {
175 std::vector<clang::CXXMethodDecl *> FoundCXXMethodDecls;
176 if (!CurCXXRecordDecl)
177 return std::vector<clang::CXXMethodDecl *>();
178 for (auto Method : CurCXXRecordDecl->methods()) {
179 if (Method->getNameAsString().compare(MethodName) == 0) {
180 FoundCXXMethodDecls.emplace_back(Method);
181 }
182 }
183 return FoundCXXMethodDecls;
184}
185
186bool isCallRelatedExpr(clang::Expr &E) {
187 return llvm::isa<clang::CallExpr>(&E) ||

Callers 1

findTestMethodMethod · 0.85

Calls 1

compareMethod · 0.80

Tested by 1

findTestMethodMethod · 0.68