summaryrefslogtreecommitdiffstats
path: root/clang/lib/Serialization/ASTWriter.cpp
diff options
context:
space:
mode:
authorBen Langmuir <blangmuir@apple.com>2016-02-04 00:55:24 +0000
committerBen Langmuir <blangmuir@apple.com>2016-02-04 00:55:24 +0000
commitf5416740fc923ed6b24784c8ce73ccf57b6edbbd (patch)
treeb038c3a830f1cf7900833848e3ddf052e84c5e63 /clang/lib/Serialization/ASTWriter.cpp
parentcb91e7d395d3f6995061d348717b717448c18503 (diff)
downloadbcm5719-llvm-f5416740fc923ed6b24784c8ce73ccf57b6edbbd.tar.gz
bcm5719-llvm-f5416740fc923ed6b24784c8ce73ccf57b6edbbd.zip
Fix predefine for __NSConstantString struct type
Per review feedback the name was wrong and it can be used outside Objective-C. Unfortunately, making the internal struct visible broke some ASTMatchers tests that assumed that the first record decl would be from user code, rather than a builtin type. I'm worried that this will also affect users' code. So this patch adds a typedef to wrap the internal struct and only makes the typedef visible to namelookup. This is sufficient to allow the ASTReader to merge the decls we need without making the struct itself visible. rdar://problem/24425801 llvm-svn: 259734
Diffstat (limited to 'clang/lib/Serialization/ASTWriter.cpp')
-rw-r--r--clang/lib/Serialization/ASTWriter.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/Serialization/ASTWriter.cpp b/clang/lib/Serialization/ASTWriter.cpp
index a590e188eca..0b28a7aa673 100644
--- a/clang/lib/Serialization/ASTWriter.cpp
+++ b/clang/lib/Serialization/ASTWriter.cpp
@@ -4154,6 +4154,8 @@ uint64_t ASTWriter::WriteASTCore(Sema &SemaRef, StringRef isysroot,
PREDEF_DECL_MAKE_INTEGER_SEQ_ID);
RegisterPredefDecl(Context.CFConstantStringTypeDecl,
PREDEF_DECL_CF_CONSTANT_STRING_ID);
+ RegisterPredefDecl(Context.CFConstantStringTagDecl,
+ PREDEF_DECL_CF_CONSTANT_STRING_TAG_ID);
// Build a record containing all of the tentative definitions in this file, in
// TentativeDefinitions order. Generally, this record will be empty for
OpenPOWER on IntegriCloud