aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--clang.xcodeproj/project.pbxproj1
-rw-r--r--include/clang/AST/ASTContext.h12
2 files changed, 12 insertions, 1 deletions
diff --git a/clang.xcodeproj/project.pbxproj b/clang.xcodeproj/project.pbxproj
index a7d7e5fae4..06a6d796fb 100644
--- a/clang.xcodeproj/project.pbxproj
+++ b/clang.xcodeproj/project.pbxproj
@@ -675,7 +675,6 @@
08FB7793FE84155DC02AAC07 /* Project object */ = {
isa = PBXProject;
buildConfigurationList = 1DEB923508733DC60010E9CD /* Build configuration list for PBXProject "clang" */;
- compatibilityVersion = "Xcode 2.4";
hasScannedForEncodings = 1;
mainGroup = 08FB7794FE84155DC02AAC07 /* clang */;
projectDirPath = "";
diff --git a/include/clang/AST/ASTContext.h b/include/clang/AST/ASTContext.h
index 1d39bb3b70..f1e0959e0c 100644
--- a/include/clang/AST/ASTContext.h
+++ b/include/clang/AST/ASTContext.h
@@ -19,6 +19,7 @@
#include "clang/AST/RecordLayout.h"
#include "clang/AST/Type.h"
#include "llvm/ADT/DenseMap.h"
+#include "llvm/ADT/StringMap.h"
#include <vector>
namespace clang {
@@ -37,6 +38,7 @@ class ASTContext {
llvm::FoldingSet<FunctionTypeProto> FunctionTypeProtos;
llvm::DenseMap<const RecordDecl*, const RecordLayout*> RecordLayoutInfo;
RecordDecl *CFConstantStringTypeDecl;
+ llvm::StringMap<char> SelectorNames;
public:
TargetInfo &Target;
IdentifierTable &Idents;
@@ -174,6 +176,16 @@ public:
/// 'typeSize' is a real floating point or complex type.
QualType getFloatingTypeOfSizeWithinDomain(QualType typeSize,
QualType typeDomain) const;
+
+ //===--------------------------------------------------------------------===//
+ // Objective-C
+ //===--------------------------------------------------------------------===//
+
+ /// getSelectorName - Return a uniqued character string for the selector.
+ char &getSelectorName(const char *NameStart, const char *NameEnd) {
+ return SelectorNames.GetOrCreateValue(NameStart, NameEnd).getValue();
+ }
+
private:
ASTContext(const ASTContext&); // DO NOT IMPLEMENT
void operator=(const ASTContext&); // DO NOT IMPLEMENT