[Macros] Implement AST printing and module interface generation for macros

This commit is contained in:
Doug Gregor
2022-11-25 10:27:25 -08:00
parent 4ce0834c51
commit 1a124e71d6
6 changed files with 87 additions and 12 deletions

View File

@@ -4314,10 +4314,7 @@ public:
uint8_t rawAccessLevel =
getRawStableAccessLevel(macro->getFormalAccess());
Type resultType = evaluateOrDefault(
S.getASTContext().evaluator,
ResultTypeRequest{const_cast<MacroDecl *>(macro)},
Type());
Type resultType = macro->getResultInterfaceType();
unsigned abbrCode = S.DeclTypeAbbrCodes[MacroLayout::Code];
MacroLayout::emitRecord(S.Out, S.ScratchRecord, abbrCode,