Revert "Don't need to mangle @nonobjc, NFC"

This reverts r32940. In reality this is not dead code, because
foreign to native thunks have the _TTO mangling. We need better
tests, which I will add in an upcoming commit.

Swift SVN r32945
This commit is contained in:
Slava Pestov
2015-10-28 18:39:54 +00:00
parent fb3627e2ee
commit 21e01730f4
3 changed files with 11 additions and 0 deletions

View File

@@ -355,6 +355,8 @@ public:
} else if (Mangled.nextIf("To")) {
topLevel->addChild(NodeFactory::create(Node::Kind::ObjCAttribute));
} else if (Mangled.nextIf("TO")) {
topLevel->addChild(NodeFactory::create(Node::Kind::NonObjCAttribute));
} else if (Mangled.nextIf("TD")) {
topLevel->addChild(NodeFactory::create(Node::Kind::DynamicAttribute));
} else if (Mangled.nextIf("Td")) {
@@ -2399,6 +2401,7 @@ private:
case Node::Kind::NativePinningAddressor:
case Node::Kind::NativePinningMutableAddressor:
case Node::Kind::NominalTypeDescriptor:
case Node::Kind::NonObjCAttribute:
case Node::Kind::Number:
case Node::Kind::ObjCAttribute:
case Node::Kind::ObjCBlock:
@@ -2997,6 +3000,9 @@ void NodePrinter::print(NodePointer pointer, bool asContext, bool suppressType)
Printer << "inout ";
print(pointer->getChild(0));
return;
case Node::Kind::NonObjCAttribute:
Printer << "@nonobjc ";
return;
case Node::Kind::ObjCAttribute:
Printer << "@objc ";
return;