Represent the name of destructors by a special DeclBaseName

No longer use the known identifier `deinit` for destructors. This allows
classes to have functions called `deinit`.
This commit is contained in:
Alex Hoppen
2017-07-14 09:50:48 +02:00
committed by Alex Hoppen
parent 2eb36e41f5
commit ebd701c4b7
18 changed files with 75 additions and 46 deletions

View File

@@ -1791,7 +1791,7 @@ void Serializer::writeCrossReference(const DeclContext *DC, uint32_t pathLen) {
bool isProtocolExt = fn->getDeclContext()->getAsProtocolExtensionContext();
XRefValuePathPieceLayout::emitRecord(Out, ScratchRecord, abbrCode,
addTypeRef(ty),
addDeclBaseNameRef(fn->getName()),
addDeclBaseNameRef(fn->getBaseName()),
isProtocolExt,
fn->isStatic());