[Markup] Add LocalizationKey simple field

To be vended as an optional part of SourceKit cursorInfo response.

rdar://problem/30383329
This commit is contained in:
David Farler
2017-02-17 11:05:19 -08:00
parent 2c56a2b25b
commit 7fa116039d
5 changed files with 10 additions and 0 deletions

View File

@@ -272,6 +272,8 @@ bool extractSimpleField(
llvm::raw_svector_ostream OS(Scratch);
printInlinesUnder(TF, OS);
Tags.insert(MC.allocateCopy(OS.str()));
} else if (auto LKF = dyn_cast<markup::LocalizationKeyField>(Field)) {
Parts.LocalizationKeyField = LKF;
} else {
BodyNodes.push_back(Field);
}