teak-llvm/clang/lib/Serialization
Douglas Gregor acf4fd3039 Stop back-patching 'readonly' Objective-C properties with 'readwrite' ones.
A 'readonly' Objective-C property declared in the primary class can
effectively be shadowed by a 'readwrite' property declared within an
extension of that class, so long as the types and attributes of the
two property declarations are compatible.

Previously, this functionality was implemented by back-patching the
original 'readonly' property to make it 'readwrite', destroying source
information and causing some hideously redundant, incorrect
code. Simplify the implementation to express how this should actually
be modeled: as a separate property declaration in the extension that
shadows (via the name lookup rules) the declaration in the primary
class. While here, correct some broken Fix-Its, eliminate a pile of
redundant code, clean up the ARC migrator's handling of properties
declared in extensions, and fix debug info's naming of methods that
come from categories.

A wonderous side effect of doing this write is that it eliminates the
"AddedObjCPropertyInClassExtension" method from the AST mutation
listener, which in turn eliminates the last place where we rewrite
entire declarations in a chained PCH file or a module file. This
change (which fixes rdar://problem/18475765) will allow us to
eliminate the rewritten-decls logic from the serialization library,
and fixes a crash (rdar://problem/23247794) illustrated by the
test/PCH/chain-categories.m example.

llvm-svn: 251874
2015-11-03 01:15:46 +00:00
..
ASTCommon.cpp Roll-back r250822. 2015-10-20 13:23:58 +00:00
ASTCommon.h [modules] Add an assert for redeclarations that we never added to their redecl 2015-07-27 05:40:23 +00:00
ASTReader.cpp Fix missing builtin identifier infos with PCH+modules 2015-10-28 22:25:37 +00:00
ASTReaderDecl.cpp Fix Clang-tidy modernize-use-nullptr warnings in source directories; other minor cleanups 2015-10-06 23:40:43 +00:00
ASTReaderInternals.h Re-commit r246497 (and dependent changes r246524 and r246521), reverted in 2015-09-01 20:35:42 +00:00
ASTReaderStmt.cpp [coroutines] Creation of promise object, lookup of operator co_await, building 2015-10-27 06:02:45 +00:00
ASTWriter.cpp Stop back-patching 'readonly' Objective-C properties with 'readwrite' ones. 2015-11-03 01:15:46 +00:00
ASTWriterDecl.cpp No functionality change, just fix whitespace, a typo and remove an unnecessary 2015-10-18 20:32:12 +00:00
ASTWriterStmt.cpp [coroutines] Creation of promise object, lookup of operator co_await, building 2015-10-27 06:02:45 +00:00
CMakeLists.txt Revert "Wrap clang module files in a Mach-O, ELF, or COFF container." 2015-02-25 02:44:04 +00:00
GeneratePCH.cpp Roll-back r250822. 2015-10-20 13:23:58 +00:00
GlobalModuleIndex.cpp EmitRecord* API change: accepts ArrayRef instead of a SmallVector (NFC) 2015-09-10 01:46:39 +00:00
Makefile
Module.cpp Re-commit r246497 (and dependent changes r246524 and r246521), reverted in 2015-09-01 20:35:42 +00:00
ModuleManager.cpp Fix use-after-free in ModuleManager 2015-10-21 23:12:45 +00:00
MultiOnDiskHashTable.h Roll-back r250822. 2015-10-20 13:23:58 +00:00