forked from OSchip/llvm-project
[libclang] Implicit objc methods are skipped, no need to check isSynthesized.
Plus, isSynthesized returning true does not mean that there is not a user-declared method declaration. llvm-svn: 137858
This commit is contained in:
parent
3b5a69cc45
commit
d8b87a8b2e
|
@ -4746,12 +4746,6 @@ AnnotateTokensWorker::Visit(CXCursor cursor, CXCursor parent) {
|
|||
const enum CXCursorKind cursorK = clang_getCursorKind(cursor);
|
||||
if (cursorK >= CXCursor_FirstDecl && cursorK <= CXCursor_LastDecl) {
|
||||
Decl *D = cxcursor::getCursorDecl(cursor);
|
||||
// Don't visit synthesized ObjC methods, since they have no syntatic
|
||||
// representation in the source.
|
||||
if (const ObjCMethodDecl *MD = dyn_cast<ObjCMethodDecl>(D)) {
|
||||
if (MD->isSynthesized())
|
||||
return CXChildVisit_Continue;
|
||||
}
|
||||
|
||||
SourceLocation StartLoc;
|
||||
if (const DeclaratorDecl *DD = dyn_cast<DeclaratorDecl>(D)) {
|
||||
|
|
Loading…
Reference in New Issue