aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGObjCGNU.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2008-11-17 14:58:09 +0000
committerDouglas Gregor <dgregor@apple.com>2008-11-17 14:58:09 +0000
commit2e1cd4264d363ca869bf37ef160902f211d21b8c (patch)
treeb4e6314529ad811be3463a668f8b4e515f66fbcc /lib/CodeGen/CGObjCGNU.cpp
parentb8abbdc90f902a2c09c566193b900c2c45a46672 (diff)
Introduction the DeclarationName class, as a single, general method of
representing the names of declarations in the C family of languages. DeclarationName is used in NamedDecl to store the name of the declaration (naturally), and ObjCMethodDecl is now a NamedDecl. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@59441 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGObjCGNU.cpp')
-rw-r--r--lib/CodeGen/CGObjCGNU.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/CodeGen/CGObjCGNU.cpp b/lib/CodeGen/CGObjCGNU.cpp
index 4726be2115..0833b0832d 100644
--- a/lib/CodeGen/CGObjCGNU.cpp
+++ b/lib/CodeGen/CGObjCGNU.cpp
@@ -561,7 +561,7 @@ llvm::Value *CGObjCGNU::GenerateProtocolRef(CGBuilderTy &Builder,
void CGObjCGNU::GenerateProtocol(const ObjCProtocolDecl *PD) {
ASTContext &Context = CGM.getContext();
- const char *ProtocolName = PD->getName();
+ const char *ProtocolName = PD->getIdentifierName();
llvm::SmallVector<std::string, 16> Protocols;
for (ObjCProtocolDecl::protocol_iterator PI = PD->protocol_begin(),
E = PD->protocol_end(); PI != E; ++PI)
@@ -616,8 +616,8 @@ void CGObjCGNU::GenerateProtocol(const ObjCProtocolDecl *PD) {
}
void CGObjCGNU::GenerateCategory(const ObjCCategoryImplDecl *OCD) {
- const char *ClassName = OCD->getClassInterface()->getName();
- const char *CategoryName = OCD->getName();
+ const char *ClassName = OCD->getClassInterface()->getIdentifierName();
+ const char *CategoryName = OCD->getIdentifierName();
// Collect information about instance methods
llvm::SmallVector<Selector, 16> InstanceMethodSels;
llvm::SmallVector<llvm::Constant*, 16> InstanceMethodTypes;
@@ -675,12 +675,12 @@ void CGObjCGNU::GenerateClass(const ObjCImplementationDecl *OID) {
OID->getClassInterface()->getSuperClass();
const char * SuperClassName = NULL;
if (SuperClassDecl) {
- SuperClassName = SuperClassDecl->getName();
+ SuperClassName = SuperClassDecl->getIdentifierName();
}
// Get the class name
ObjCInterfaceDecl * ClassDecl = (ObjCInterfaceDecl*)OID->getClassInterface();
- const char * ClassName = ClassDecl->getName();
+ const char * ClassName = ClassDecl->getIdentifierName();
// Get the size of instances. For runtimes that support late-bound instances
// this should probably be something different (size just of instance