mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Generalize @attached parsing and representation to also include @freestanding.
The attached and freestanding macro attributes use the same parsing logic and representation, so generalize the "attached" attribute into a more general "macro role" attribute.
This commit is contained in:
@@ -2226,10 +2226,11 @@ namespace decls_block {
|
||||
BCArray<IdentifierIDField> // introduced decl name kind and identifier pairs
|
||||
>;
|
||||
|
||||
using AttachedDeclAttrLayout = BCRecordLayout<
|
||||
Attached_DECL_ATTR,
|
||||
using MacroRoleDeclAttrLayout = BCRecordLayout<
|
||||
MacroRole_DECL_ATTR,
|
||||
BCFixed<1>, // implicit flag
|
||||
MacroRoleField, // macro roles
|
||||
BCFixed<1>, // macro syntax
|
||||
MacroRoleField, // macro role
|
||||
BCVBR<5>, // number of names
|
||||
BCArray<IdentifierIDField> // introduced decl name kind and identifier pairs
|
||||
>;
|
||||
|
||||
Reference in New Issue
Block a user