Skip to content

Commit bd6ebcd

Browse files
committed
[gardening] Add some comments to SILIsolationInfo's header file.
(cherry picked from commit c1ddeb2)
1 parent 7cf82b7 commit bd6ebcd

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

include/swift/SILOptimizer/Utils/SILIsolationInfo.h

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,15 +120,26 @@ class ActorInstance {
120120
/// matching.
121121
class SILIsolationInfo {
122122
public:
123-
/// The lattice is:
123+
/// This forms a lattice of semantics. The lattice progresses from left ->
124+
/// right below:
124125
///
125126
/// Unknown -> Disconnected -> TransferringParameter -> Task -> Actor.
126127
///
127-
/// Unknown means no information. We error when merging on it.
128128
enum Kind : uint8_t {
129+
/// Unknown means no information. We error when merging on it.
129130
Unknown,
131+
132+
/// An entity with disconnected isolation can be freely transferred into
133+
/// another isolation domain. These are associated with "use after transfer"
134+
/// diagnostics.
130135
Disconnected,
136+
137+
/// An entity that is in the same region as a task-isolated value. Cannot be
138+
/// sent into another isolation domain.
131139
Task,
140+
141+
/// An entity that is in the same region as an actor-isolated value. Cannot
142+
/// be sent into another isolation domain.
132143
Actor,
133144
};
134145

0 commit comments

Comments
 (0)