[cfe-commits] r43987 - /cfe/trunk/Sema/SemaDecl.cpp
Fariborz Jahanian
fjahanian at apple.com
Sat Nov 10 14:00:56 PST 2007
Author: fjahanian
Date: Sat Nov 10 16:00:55 2007
New Revision: 43987
URL: http://llvm.org/viewvc/llvm-project?rev=43987&view=rev
Log:
Fixed a bug which exposed the internally built type to user code.
Modified:
cfe/trunk/Sema/SemaDecl.cpp
Modified: cfe/trunk/Sema/SemaDecl.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/Sema/SemaDecl.cpp?rev=43987&r1=43986&r2=43987&view=diff
==============================================================================
--- cfe/trunk/Sema/SemaDecl.cpp (original)
+++ cfe/trunk/Sema/SemaDecl.cpp Sat Nov 10 16:00:55 2007
@@ -551,8 +551,13 @@
ObjcMethodDecl *MDecl = dyn_cast<ObjcMethodDecl>(static_cast<Decl *>(D));
ScopedDecl *LastDeclarator = dyn_cast_or_null<ScopedDecl>((Decl *)lastDecl);
- const char *name = MDecl->getSelector().getName().c_str();
- IdentifierInfo *II = &Context.Idents.get(name);
+ // build [classname selector-name] for the name of method.
+ std::string Name = "[";
+ Name += MDecl->getClassInterface()->getName();
+ Name += " ";
+ Name += MDecl->getSelector().getName();
+ Name += "]";
+ IdentifierInfo *II = &Context.Idents.get(Name);
assert (II && "ObjcActOnMethodDefinition - selector name is missing");
// The scope passed in may not be a decl scope. Zip up the scope tree until
More information about the cfe-commits
mailing list