//===--- CSTrail.def - Trail Change Kinds ---------------------------------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2024 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/LICENSE.txt for license information
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//
///
/// This file enumerates the kinds of SolverTrail::Change.
///
//===----------------------------------------------------------------------===//

#ifndef CHANGE
#define CHANGE(Name)
#endif

#ifndef LOCATOR_CHANGE
#define LOCATOR_CHANGE(Name, Map) CHANGE(Name)
#endif

#ifndef EXPR_CHANGE
#define EXPR_CHANGE(Name) CHANGE(Name)
#endif

#ifndef CLOSURE_CHANGE
#define CLOSURE_CHANGE(Name) CHANGE(Name)
#endif

#ifndef CONSTRAINT_CHANGE
#define CONSTRAINT_CHANGE(Name) CHANGE(Name)
#endif

#ifndef GRAPH_NODE_CHANGE
#define GRAPH_NODE_CHANGE(Name) CHANGE(Name)
#endif

#ifndef BINDING_RELATION_CHANGE
#define BINDING_RELATION_CHANGE(Name) CHANGE(Name)
#endif

#ifndef SCORE_CHANGE
#define SCORE_CHANGE(Name) CHANGE(Name)
#endif

#ifndef LAST_CHANGE
#define LAST_CHANGE(Name)
#endif

LOCATOR_CHANGE(RecordedDisjunctionChoice, DisjunctionChoices)
LOCATOR_CHANGE(RecordedAppliedDisjunction, AppliedDisjunctions)
LOCATOR_CHANGE(RecordedMatchCallArgumentResult, argumentMatchingChoices)
LOCATOR_CHANGE(RecordedOpenedTypes, OpenedTypes)
LOCATOR_CHANGE(RecordedOpenedExistentialType, OpenedExistentialTypes)
LOCATOR_CHANGE(RecordedDefaultedConstraint, DefaultedConstraints)
LOCATOR_CHANGE(ResolvedOverload, ResolvedOverloads)
LOCATOR_CHANGE(RecordedArgumentList, ArgumentLists)
LOCATOR_CHANGE(RecordedImplicitCallAsFunctionRoot, ImplicitCallAsFunctionRoots)
LOCATOR_CHANGE(RecordedSynthesizedConformance, SynthesizedConformances)

EXPR_CHANGE(AppliedPropertyWrapper)
EXPR_CHANGE(RecordedImpliedResult)
EXPR_CHANGE(RecordedExprPattern)

CLOSURE_CHANGE(RecordedClosureType)
CLOSURE_CHANGE(RecordedPreconcurrencyClosure)

CONSTRAINT_CHANGE(DisabledConstraint)
CONSTRAINT_CHANGE(FavoredConstraint)
CONSTRAINT_CHANGE(GeneratedConstraint)

GRAPH_NODE_CHANGE(AddedConstraint)
GRAPH_NODE_CHANGE(RemovedConstraint)
GRAPH_NODE_CHANGE(InferredBindings)
GRAPH_NODE_CHANGE(RetractedBindings)
GRAPH_NODE_CHANGE(RetractedDelayedBy)

BINDING_RELATION_CHANGE(RetractedAdjacentVar)
BINDING_RELATION_CHANGE(RetractedSubtypeOf)
BINDING_RELATION_CHANGE(RetractedSupertypeOf)
BINDING_RELATION_CHANGE(RetractedEquivalentTo)

SCORE_CHANGE(IncreasedScore)
SCORE_CHANGE(DecreasedScore)

CHANGE(AddedTypeVariable)
CHANGE(ExtendedEquivalenceClass)
CHANGE(RelatedTypeVariables)
CHANGE(UpdatedTypeVariable)
CHANGE(AddedConversionRestriction)
CHANGE(AddedFix)
CHANGE(AddedFixedRequirement)
CHANGE(RecordedOpenedPackExpansionType)
CHANGE(RecordedPackElementExpansion)
CHANGE(RecordedPackExpansionEnvironment)
CHANGE(RecordedNodeType)
CHANGE(RecordedKeyPathComponentType)
CHANGE(RecordedResultBuilderTransform)
CHANGE(RecordedContextualInfo)
CHANGE(RecordedTarget)
CHANGE(RecordedCaseLabelItemInfo)
CHANGE(RecordedPotentialThrowSite)
CHANGE(RecordedIsolatedParam)
CHANGE(RecordedKeyPath)
CHANGE(RetiredConstraint)
CHANGE(RetractedBinding)

LAST_CHANGE(RetractedBinding)

#undef LOCATOR_CHANGE
#undef EXPR_CHANGE
#undef CLOSURE_CHANGE
#undef CONSTRAINT_CHANGE
#undef GRAPH_NODE_CHANGE
#undef BINDING_RELATION_CHANGE
#undef SCORE_CHANGE
#undef LAST_CHANGE
#undef CHANGE
