Sema: Record case label items in the trail

This commit is contained in:
Slava Pestov
2024-10-04 13:24:44 -04:00
parent 8c8a385a4a
commit 39d0eab275
5 changed files with 38 additions and 15 deletions

View File

@@ -132,6 +132,7 @@ public:
AnyFunctionRef TheRef;
ClosureExpr *TheClosure;
DeclContext *TheDeclContext;
CaseLabelItem *TheItem;
};
Change() : Kind(ChangeKind::AddedTypeVariable), TypeVar(nullptr) { }
@@ -220,6 +221,9 @@ public:
/// Create a change that recorded a SyntacticElementTarget.
static Change RecordedTarget(SyntacticElementTargetKey key);
/// Create a change that recorded a SyntacticElementTarget.
static Change RecordedCaseLabelItemInfo(CaseLabelItem *item);
/// Undo this change, reverting the constraint graph to the state it
/// had prior to this change.
///