mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Merge pull request #63075 from hborla/macro-attribute-serialization
[Serialization] Don't serialize macro custom attributes.
This commit is contained in:
@@ -2855,6 +2855,11 @@ class Serializer::DeclSerializer : public DeclVisitor<DeclSerializer> {
|
||||
case DAK_Custom: {
|
||||
auto abbrCode = S.DeclTypeAbbrCodes[CustomDeclAttrLayout::Code];
|
||||
auto theAttr = cast<CustomAttr>(DA);
|
||||
|
||||
// Macro attributes are not serialized.
|
||||
if (theAttr->isAttachedMacro(D))
|
||||
return;
|
||||
|
||||
auto typeID = S.addTypeRef(theAttr->getType());
|
||||
if (!typeID && !S.allowCompilerErrors()) {
|
||||
llvm::PrettyStackTraceString message("CustomAttr has no type");
|
||||
|
||||
Reference in New Issue
Block a user