@@ -120,11 +120,8 @@ class GenericSignatureBuilder {
120
120
llvm::MapVector<ProtocolDecl *, std::vector<Constraint<ProtocolDecl *>>>
121
121
conformsTo;
122
122
123
- // / Same-type constraints between each potential archetype and any other
124
- // / archetype in its equivalence class.
125
- llvm::MapVector<PotentialArchetype *,
126
- std::vector<Constraint<PotentialArchetype *>>>
127
- sameTypeConstraints;
123
+ // / Same-type constraints within this equivalence class.
124
+ std::vector<Constraint<PotentialArchetype *>> sameTypeConstraints;
128
125
129
126
// / Concrete type to which this equivalence class is equal.
130
127
// /
@@ -218,8 +215,7 @@ class GenericSignatureBuilder {
218
215
// /
219
216
// / \returns true if this same-type constraint merges two equivalence
220
217
// / classes, and false otherwise.
221
- bool recordSameTypeConstraint (GenericSignatureBuilder &builder,
222
- PotentialArchetype *type1,
218
+ bool recordSameTypeConstraint (PotentialArchetype *type1,
223
219
PotentialArchetype *type2,
224
220
const RequirementSource *source);
225
221
@@ -1669,18 +1665,6 @@ class GenericSignatureBuilder::PotentialArchetype {
1669
1665
// / potential archetype computations.
1670
1666
PotentialArchetype *getArchetypeAnchor (GenericSignatureBuilder &builder);
1671
1667
1672
- // / Retrieve the same-type constraints.
1673
- ArrayRef<Constraint<PotentialArchetype *>> getSameTypeConstraints () const {
1674
- if (auto equivClass = getEquivalenceClassIfPresent ()) {
1675
- auto known = equivClass->sameTypeConstraints .find (
1676
- const_cast <PotentialArchetype *>(this ));
1677
- if (known == equivClass->sameTypeConstraints .end ()) return { };
1678
- return known->second ;
1679
- }
1680
-
1681
- return { };
1682
- }
1683
-
1684
1668
// / \brief Retrieve (or create) a nested type that is the current best
1685
1669
// / nested archetype anchor (locally) with the given name.
1686
1670
// /
0 commit comments