[Concurrency] Add support for @GlobalActor(unsafe).

Allow us to tag declarations that are meant to be in a global actor, but
for which we don't yet want to enforce everything. This will be used for
better staging-in of global actor annotations, but for now it's a fancy
way to document @actorIndependent(unsafe).

Stages in the syntax for rdar://74241687 without really implementing it.
This commit is contained in:
Doug Gregor
2021-02-25 22:41:32 -08:00
parent 62a5d1c2ce
commit 451e6cc1f5
12 changed files with 115 additions and 12 deletions

View File

@@ -56,7 +56,7 @@ const uint16_t SWIFTMODULE_VERSION_MAJOR = 0;
/// describe what change you made. The content of this comment isn't important;
/// it just ensures a conflict if two people change the module format.
/// Don't worry about adhering to the 80-column limit for this line.
const uint16_t SWIFTMODULE_VERSION_MINOR = 599; // has-async-alternative
const uint16_t SWIFTMODULE_VERSION_MINOR = 600; // custom attr (unsafe)
/// A standard hash seed used for all string hashes in a serialized module.
///
@@ -1943,9 +1943,9 @@ namespace decls_block {
using CustomDeclAttrLayout = BCRecordLayout<
Custom_DECL_ATTR,
BCFixed<1>, // implicit flag
TypeIDField // type referenced by this custom attribute
TypeIDField, // type referenced by this custom attribute
BCFixed<1> // is the argument (unsafe)
>;
}
/// Returns the encoding kind for the given decl.