diff options
author | Douglas Gregor <dgregor@apple.com> | 2012-01-14 16:38:05 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2012-01-14 16:38:05 +0000 |
commit | ec9fd13c775ae53ecde15da9bb725e66a7e52664 (patch) | |
tree | af59921e4cb903673bd786592979581ce449d270 /clang/tools/libclang/IndexingContext.h | |
parent | b009517ad48365a16f45d482deea28a4af40ebaa (diff) | |
download | bcm5719-llvm-ec9fd13c775ae53ecde15da9bb725e66a7e52664.tar.gz bcm5719-llvm-ec9fd13c775ae53ecde15da9bb725e66a7e52664.zip |
De-virtualize getPreviousDecl() and getMostRecentDecl() when we know
we have a redeclarable type, and only use the new virtual versions
(getPreviousDeclImpl() and getMostRecentDeclImpl()) when we don't have
that type information. This keeps us from penalizing users with strict
type information (and is the moral equivalent of a "final" method).
Plus, settle on the names getPreviousDecl() and getMostRecentDecl()
throughout.
llvm-svn: 148187
Diffstat (limited to 'clang/tools/libclang/IndexingContext.h')
-rw-r--r-- | clang/tools/libclang/IndexingContext.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/tools/libclang/IndexingContext.h b/clang/tools/libclang/IndexingContext.h index 4a321204a8c..26b8ecb75d0 100644 --- a/clang/tools/libclang/IndexingContext.h +++ b/clang/tools/libclang/IndexingContext.h @@ -127,7 +127,7 @@ struct ObjCInterfaceDeclInfo : public ObjCContainerDeclInfo { ObjCInterfaceDeclInfo(const ObjCInterfaceDecl *D) : ObjCContainerDeclInfo(Info_ObjCInterface, /*isForwardRef=*/false, - /*isRedeclaration=*/D->getPreviousDeclaration() != 0, + /*isRedeclaration=*/D->getPreviousDecl() != 0, /*isImplementation=*/false) { } static bool classof(const DeclInfo *D) { @@ -142,7 +142,7 @@ struct ObjCProtocolDeclInfo : public ObjCContainerDeclInfo { ObjCProtocolDeclInfo(const ObjCProtocolDecl *D) : ObjCContainerDeclInfo(Info_ObjCProtocol, /*isForwardRef=*/false, - /*isRedeclaration=*/D->getPreviousDeclaration(), + /*isRedeclaration=*/D->getPreviousDecl(), /*isImplementation=*/false) { } static bool classof(const DeclInfo *D) { |