Skip to content

Commit b1a035a

Browse files
committed
Rename GadtConstraintHandling to GadtState
1 parent 8d1e5df commit b1a035a

14 files changed

+63
-73
lines changed

compiler/src/dotty/tools/dotc/core/Contexts.scala

+11-10
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,8 @@ object Contexts {
141141
def tree: Tree[?]
142142
def scope: Scope
143143
def typerState: TyperState
144-
def gadt: GadtConstraintHandling
144+
def gadt: GadtConstraint = gadtState.gadt
145+
def gadtState: GadtState
145146
def searchHistory: SearchHistory
146147
def source: SourceFile
147148

@@ -410,7 +411,7 @@ object Contexts {
410411
val constrCtx = outersIterator.dropWhile(_.outer.owner == owner).next()
411412
superOrThisCallContext(owner, constrCtx.scope)
412413
.setTyperState(typerState)
413-
.setGadt(gadt)
414+
.setGadtState(gadtState)
414415
.fresh
415416
.setScope(this.scope)
416417
}
@@ -541,8 +542,8 @@ object Contexts {
541542
private var _typerState: TyperState = uninitialized
542543
final def typerState: TyperState = _typerState
543544

544-
private var _gadt: GadtConstraintHandling = uninitialized
545-
final def gadt: GadtConstraintHandling = _gadt
545+
private var _gadtState: GadtState = uninitialized
546+
final def gadtState: GadtState = _gadtState
546547

547548
private var _searchHistory: SearchHistory = uninitialized
548549
final def searchHistory: SearchHistory = _searchHistory
@@ -567,7 +568,7 @@ object Contexts {
567568
_owner = origin.owner
568569
_tree = origin.tree
569570
_scope = origin.scope
570-
_gadt = origin.gadt
571+
_gadtState = origin.gadtState
571572
_searchHistory = origin.searchHistory
572573
_source = origin.source
573574
_moreProperties = origin.moreProperties
@@ -624,12 +625,12 @@ object Contexts {
624625
this._scope = typer.scope
625626
setTypeAssigner(typer)
626627

627-
def setGadt(gadt: GadtConstraintHandling): this.type =
628-
util.Stats.record("Context.setGadt")
629-
this._gadt = gadt
628+
def setGadtState(gadtState: GadtState): this.type =
629+
util.Stats.record("Context.setGadtState")
630+
this._gadtState = gadtState
630631
this
631632
def setFreshGADTBounds: this.type =
632-
setGadt(gadt.fresh)
633+
setGadtState(gadtState.fresh)
633634

634635
def setSearchHistory(searchHistory: SearchHistory): this.type =
635636
util.Stats.record("Context.setSearchHistory")
@@ -721,7 +722,7 @@ object Contexts {
721722
.updated(notNullInfosLoc, Nil)
722723
.updated(compilationUnitLoc, NoCompilationUnit)
723724
c._searchHistory = new SearchRoot
724-
c._gadt = GadtConstraintHandling(GadtConstraint.empty)
725+
c._gadtState = GadtState(GadtConstraint.empty)
725726
c
726727
end FreshContext
727728

compiler/src/dotty/tools/dotc/core/GadtConstraint.scala

+11-22
Original file line numberDiff line numberDiff line change
@@ -133,20 +133,14 @@ class GadtConstraint private (
133133
): GadtConstraint = GadtConstraint(myConstraint, mapping, reverseMapping, wasConstrained)
134134
end GadtConstraint
135135

136-
object GadtConstraintHandling:
137-
def apply(gadt: GadtConstraint): GadtConstraintHandling = new ProperGadtConstraintHandling(gadt)
136+
object GadtState:
137+
def apply(gadt: GadtConstraint): GadtState = ProperGadtState(gadt)
138138

139-
sealed trait GadtConstraintHandling(private var myGadt: GadtConstraint) {
140-
this: ConstraintHandling =>
139+
sealed trait GadtState {
140+
this: ConstraintHandling => // Hide ConstraintHandling within GadtConstraintHandling
141141

142-
def gadt: GadtConstraint = myGadt
143-
private def gadt_=(g: GadtConstraint) = myGadt = g
144-
145-
/** Exposes ConstraintHandling.subsumes */
146-
def subsumes(left: GadtConstraint, right: GadtConstraint, pre: GadtConstraint)(using Context): Boolean = {
147-
def extractConstraint(g: GadtConstraint) = g.constraint
148-
subsumes(extractConstraint(left), extractConstraint(right), extractConstraint(pre))
149-
}
142+
def gadt: GadtConstraint
143+
def gadt_=(g: GadtConstraint): Unit
150144

151145
override protected def legalBound(param: TypeParamRef, rawBound: Type, isUpper: Boolean)(using Context): Type =
152146
// GADT constraints never involve wildcards and are not propagated outside
@@ -233,13 +227,6 @@ sealed trait GadtConstraintHandling(private var myGadt: GadtConstraint) {
233227
result
234228
}
235229

236-
def isLess(sym1: Symbol, sym2: Symbol)(using Context): Boolean = gadt.isLess(sym1, sym2)
237-
def fullBounds(sym: Symbol)(using Context): TypeBounds | Null = gadt.fullBounds(sym)
238-
def bounds(sym: Symbol)(using Context): TypeBounds | Null = gadt.bounds(sym)
239-
def contains(sym: Symbol)(using Context): Boolean = gadt.contains(sym)
240-
def isNarrowing: Boolean = gadt.isNarrowing
241-
def symbols: List[Symbol] = gadt.symbols
242-
243230
/** See [[ConstraintHandling.approximation]] */
244231
def approximation(sym: Symbol, fromBelow: Boolean, maxLevel: Int = Int.MaxValue)(using Context): Type = {
245232
approximation(gadt.tvarOrError(sym).origin, fromBelow, maxLevel).match
@@ -252,7 +239,7 @@ sealed trait GadtConstraintHandling(private var myGadt: GadtConstraint) {
252239
.showing(i"approximating $sym ~> $result", gadts)
253240
}
254241

255-
def fresh: GadtConstraintHandling = GadtConstraintHandling(gadt)
242+
def fresh: GadtState = GadtState(gadt)
256243

257244
/** Restore the GadtConstraint state. */
258245
def restore(gadt: GadtConstraint): Unit = this.gadt = gadt
@@ -281,5 +268,7 @@ sealed trait GadtConstraintHandling(private var myGadt: GadtConstraint) {
281268
override def constr = gadtsConstr
282269
}
283270

284-
// Hide ConstraintHandling within GadtConstraintHandling
285-
private class ProperGadtConstraintHandling(gadt: GadtConstraint) extends ConstraintHandling with GadtConstraintHandling(gadt)
271+
// Hide ConstraintHandling within GadtState
272+
private class ProperGadtState(private var myGadt: GadtConstraint) extends ConstraintHandling with GadtState:
273+
def gadt: GadtConstraint = myGadt
274+
def gadt_=(gadt: GadtConstraint): Unit = myGadt = gadt

compiler/src/dotty/tools/dotc/core/NamerOps.scala

+3-3
Original file line numberDiff line numberDiff line change
@@ -212,11 +212,11 @@ object NamerOps:
212212
* by (ab?)-using GADT constraints. See pos/i941.scala.
213213
*/
214214
def linkConstructorParams(sym: Symbol, tparams: List[Symbol], rhsCtx: Context)(using Context): Unit =
215-
rhsCtx.gadt.addToConstraint(tparams)
215+
rhsCtx.gadtState.addToConstraint(tparams)
216216
tparams.lazyZip(sym.owner.typeParams).foreach { (psym, tparam) =>
217217
val tr = tparam.typeRef
218-
rhsCtx.gadt.addBound(psym, tr, isUpper = false)
219-
rhsCtx.gadt.addBound(psym, tr, isUpper = true)
218+
rhsCtx.gadtState.addBound(psym, tr, isUpper = false)
219+
rhsCtx.gadtState.addBound(psym, tr, isUpper = true)
220220
}
221221

222222
end NamerOps

compiler/src/dotty/tools/dotc/core/PatternTypeConstrainer.scala

+2-2
Original file line numberDiff line numberDiff line change
@@ -261,12 +261,12 @@ trait PatternTypeConstrainer { self: TypeComparer =>
261261
val assumeInvariantRefinement =
262262
migrateTo3 || forceInvariantRefinement || refinementIsInvariant(patternTp)
263263

264-
trace(i"constraining simple pattern type $tp >:< $pt", gadts, (res: Boolean) => i"$res gadt = ${ctx.gadt.gadt}") {
264+
trace(i"constraining simple pattern type $tp >:< $pt", gadts, (res: Boolean) => i"$res gadt = ${ctx.gadt}") {
265265
(tp, pt) match {
266266
case (AppliedType(tyconS, argsS), AppliedType(tyconP, argsP)) =>
267267
val saved = state.nn.constraint
268268
val result =
269-
ctx.gadt.rollbackGadtUnless {
269+
ctx.gadtState.rollbackGadtUnless {
270270
tyconS.typeParams.lazyZip(argsS).lazyZip(argsP).forall { (param, argS, argP) =>
271271
val variance = param.paramVarianceSign
272272
if variance == 0 || assumeInvariantRefinement ||

compiler/src/dotty/tools/dotc/core/Symbols.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -686,7 +686,7 @@ object Symbols {
686686
addToGadt: Boolean = true,
687687
flags: FlagSet = EmptyFlags)(using Context): Symbol = {
688688
val sym = newSymbol(ctx.owner, name, Case | flags, info, coord = span)
689-
if (addToGadt && name.isTypeName) ctx.gadt.addToConstraint(sym)
689+
if (addToGadt && name.isTypeName) ctx.gadtState.addToConstraint(sym)
690690
sym
691691
}
692692

compiler/src/dotty/tools/dotc/core/TypeComparer.scala

+16-16
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
116116
private def isBottom(tp: Type) = tp.widen.isRef(NothingClass)
117117

118118
protected def gadtBounds(sym: Symbol)(using Context) = ctx.gadt.bounds(sym)
119-
protected def gadtAddBound(sym: Symbol, b: Type, isUpper: Boolean): Boolean = ctx.gadt.addBound(sym, b, isUpper)
119+
protected def gadtAddBound(sym: Symbol, b: Type, isUpper: Boolean): Boolean = ctx.gadtState.addBound(sym, b, isUpper)
120120

121121
protected def typeVarInstance(tvar: TypeVar)(using Context): Type = tvar.underlying
122122

@@ -1446,10 +1446,10 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
14461446
else if tp1 eq tp2 then true
14471447
else
14481448
val savedCstr = constraint
1449-
val savedGadt = ctx.gadt.gadt
1449+
val savedGadt = ctx.gadt
14501450
inline def restore() =
14511451
state.constraint = savedCstr
1452-
ctx.gadt.restore(savedGadt)
1452+
ctx.gadtState.restore(savedGadt)
14531453
val savedSuccessCount = successCount
14541454
try
14551455
recCount += 1
@@ -1855,34 +1855,34 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
18551855
*/
18561856
private def necessaryEither(op1: => Boolean, op2: => Boolean): Boolean =
18571857
val preConstraint = constraint
1858-
val preGadtHandling = ctx.gadt.fresh
1859-
val preGadt = preGadtHandling.gadt
1858+
val preGadt = ctx.gadt
18601859

18611860
def allSubsumes(leftGadt: GadtConstraint, rightGadt: GadtConstraint, left: Constraint, right: Constraint): Boolean =
1862-
subsumes(left, right, preConstraint) && preGadtHandling.subsumes(leftGadt, rightGadt, preGadt)
1861+
subsumes(left, right, preConstraint)
1862+
&& subsumes(leftGadt.constraint, rightGadt.constraint, preGadt.constraint)
18631863

18641864
if op1 then
18651865
val op1Constraint = constraint
1866-
val op1Gadt = ctx.gadt.gadt
1866+
val op1Gadt = ctx.gadt
18671867
constraint = preConstraint
1868-
ctx.gadt.restore(preGadt)
1868+
ctx.gadtState.restore(preGadt)
18691869
if op2 then
1870-
if allSubsumes(op1Gadt, ctx.gadt.gadt, op1Constraint, constraint) then
1871-
gadts.println(i"GADT CUT - prefer ${ctx.gadt.gadt} over $op1Gadt")
1870+
if allSubsumes(op1Gadt, ctx.gadt, op1Constraint, constraint) then
1871+
gadts.println(i"GADT CUT - prefer ${ctx.gadt} over $op1Gadt")
18721872
constr.println(i"CUT - prefer $constraint over $op1Constraint")
1873-
else if allSubsumes(ctx.gadt.gadt, op1Gadt, constraint, op1Constraint) then
1874-
gadts.println(i"GADT CUT - prefer $op1Gadt over ${ctx.gadt.gadt}")
1873+
else if allSubsumes(ctx.gadt, op1Gadt, constraint, op1Constraint) then
1874+
gadts.println(i"GADT CUT - prefer $op1Gadt over ${ctx.gadt}")
18751875
constr.println(i"CUT - prefer $op1Constraint over $constraint")
18761876
constraint = op1Constraint
1877-
ctx.gadt.restore(op1Gadt)
1877+
ctx.gadtState.restore(op1Gadt)
18781878
else
18791879
gadts.println(i"GADT CUT - no constraint is preferable, reverting to $preGadt")
18801880
constr.println(i"CUT - no constraint is preferable, reverting to $preConstraint")
18811881
constraint = preConstraint
1882-
ctx.gadt.restore(preGadt)
1882+
ctx.gadtState.restore(preGadt)
18831883
else
18841884
constraint = op1Constraint
1885-
ctx.gadt.restore(op1Gadt)
1885+
ctx.gadtState.restore(op1Gadt)
18861886
true
18871887
else op2
18881888
end necessaryEither
@@ -2054,7 +2054,7 @@ class TypeComparer(@constructorOnly initctx: Context) extends ConstraintHandling
20542054
gadts.println(i"narrow gadt bound of $tparam: ${tparam.info} from ${if (isUpper) "above" else "below"} to $bound ${bound.toString} ${bound.isRef(tparam)}")
20552055
if (bound.isRef(tparam)) false
20562056
else
2057-
ctx.gadt.rollbackGadtUnless(gadtAddBound(tparam, bound, isUpper))
2057+
ctx.gadtState.rollbackGadtUnless(gadtAddBound(tparam, bound, isUpper))
20582058
}
20592059
}
20602060

compiler/src/dotty/tools/dotc/core/TypeOps.scala

+3-3
Original file line numberDiff line numberDiff line change
@@ -687,8 +687,8 @@ object TypeOps:
687687
val bound1 = massage(bound)
688688
if (bound1 ne bound) {
689689
if (checkCtx eq ctx) checkCtx = ctx.fresh.setFreshGADTBounds
690-
if (!checkCtx.gadt.contains(sym)) checkCtx.gadt.addToConstraint(sym)
691-
checkCtx.gadt.addBound(sym, bound1, fromBelow)
690+
if (!checkCtx.gadt.contains(sym)) checkCtx.gadtState.addToConstraint(sym)
691+
checkCtx.gadtState.addBound(sym, bound1, fromBelow)
692692
typr.println("install GADT bound $bound1 for when checking F-bounded $sym")
693693
}
694694
}
@@ -872,7 +872,7 @@ object TypeOps:
872872
case tp: TypeRef if tp.symbol.exists && !tp.symbol.isClass => foldOver(tp.symbol :: xs, tp)
873873
case tp => foldOver(xs, tp)
874874
val syms2 = getAbstractSymbols(Nil, tp2).reverse
875-
if syms2.nonEmpty then ctx.gadt.addToConstraint(syms2)
875+
if syms2.nonEmpty then ctx.gadtState.addToConstraint(syms2)
876876

877877
// If parent contains a reference to an abstract type, then we should
878878
// refine subtype checking to eliminate abstract types according to

compiler/src/dotty/tools/dotc/inlines/InlineReducer.scala

+2-2
Original file line numberDiff line numberDiff line change
@@ -311,11 +311,11 @@ class InlineReducer(inliner: Inliner)(using Context):
311311
def addTypeBindings(typeBinds: TypeBindsMap)(using Context): Unit =
312312
typeBinds.foreachBinding { case (sym, shouldBeMinimized) =>
313313
newTypeBinding(sym,
314-
ctx.gadt.approximation(sym, fromBelow = shouldBeMinimized, maxLevel = Int.MaxValue))
314+
ctx.gadtState.approximation(sym, fromBelow = shouldBeMinimized, maxLevel = Int.MaxValue))
315315
}
316316

317317
def registerAsGadtSyms(typeBinds: TypeBindsMap)(using Context): Unit =
318-
if (typeBinds.size > 0) ctx.gadt.addToConstraint(typeBinds.keys)
318+
if (typeBinds.size > 0) ctx.gadtState.addToConstraint(typeBinds.keys)
319319

320320
pat match {
321321
case Typed(pat1, tpt) =>

compiler/src/dotty/tools/dotc/transform/PostTyper.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ class PostTyper extends MacroTransform with IdentityDenotTransformer { thisPhase
269269
case CaseDef(pat, _, _) =>
270270
val gadtCtx =
271271
pat.removeAttachment(typer.Typer.InferredGadtConstraints) match
272-
case Some(gadt) => ctx.fresh.setGadt(GadtConstraintHandling(gadt))
272+
case Some(gadt) => ctx.fresh.setGadtState(GadtState(gadt))
273273
case None =>
274274
ctx
275275
super.transform(tree)(using gadtCtx)

compiler/src/dotty/tools/dotc/typer/Implicits.scala

+5-5
Original file line numberDiff line numberDiff line change
@@ -1030,8 +1030,8 @@ trait Implicits:
10301030
case result: SearchSuccess =>
10311031
if result.tstate ne ctx.typerState then
10321032
result.tstate.commit()
1033-
if result.gstate ne ctx.gadt.gadt then
1034-
ctx.gadt.restore(result.gstate)
1033+
if result.gstate ne ctx.gadt then
1034+
ctx.gadtState.restore(result.gstate)
10351035
if hasSkolem(false, result.tree) then
10361036
report.error(SkolemInInferred(result.tree, pt, argument), ctx.source.atSpan(span))
10371037
implicits.println(i"success: $result")
@@ -1145,7 +1145,7 @@ trait Implicits:
11451145
SearchFailure(adapted.withType(new MismatchedImplicit(ref, pt, argument)))
11461146
}
11471147
else
1148-
SearchSuccess(adapted, ref, cand.level, cand.isExtension)(ctx.typerState, ctx.gadt.gadt)
1148+
SearchSuccess(adapted, ref, cand.level, cand.isExtension)(ctx.typerState, ctx.gadt)
11491149
}
11501150

11511151
/** An implicit search; parameters as in `inferImplicit` */
@@ -1343,7 +1343,7 @@ trait Implicits:
13431343
case _: SearchFailure =>
13441344
SearchSuccess(ref(defn.NotGiven_value), defn.NotGiven_value.termRef, 0)(
13451345
ctx.typerState.fresh().setCommittable(true),
1346-
ctx.gadt.gadt
1346+
ctx.gadt
13471347
)
13481348
case _: SearchSuccess =>
13491349
NoMatchingImplicitsFailure
@@ -1526,7 +1526,7 @@ trait Implicits:
15261526
// other candidates need to be considered.
15271527
recursiveRef match
15281528
case ref: TermRef =>
1529-
SearchSuccess(tpd.ref(ref).withSpan(span.startPos), ref, 0)(ctx.typerState, ctx.gadt.gadt)
1529+
SearchSuccess(tpd.ref(ref).withSpan(span.startPos), ref, 0)(ctx.typerState, ctx.gadt)
15301530
case _ =>
15311531
searchImplicit(contextual = true)
15321532
end bestImplicit

compiler/src/dotty/tools/dotc/typer/Inferencing.scala

+2-2
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ object Inferencing {
262262
&& ctx.gadt.contains(tp.symbol)
263263
=>
264264
val sym = tp.symbol
265-
val res = ctx.gadt.approximation(sym, fromBelow = variance < 0)
265+
val res = ctx.gadtState.approximation(sym, fromBelow = variance < 0)
266266
gadts.println(i"approximated $tp ~~ $res")
267267
res
268268

@@ -432,7 +432,7 @@ object Inferencing {
432432
}
433433

434434
// We add the created symbols to GADT constraint here.
435-
if (res.nonEmpty) ctx.gadt.addToConstraint(res)
435+
if (res.nonEmpty) ctx.gadtState.addToConstraint(res)
436436
res
437437
}
438438

compiler/src/dotty/tools/dotc/typer/Namer.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -1864,7 +1864,7 @@ class Namer { typer: Typer =>
18641864
// so we must allow constraining its type parameters
18651865
// compare with typedDefDef, see tests/pos/gadt-inference.scala
18661866
rhsCtx.setFreshGADTBounds
1867-
rhsCtx.gadt.addToConstraint(typeParams)
1867+
rhsCtx.gadtState.addToConstraint(typeParams)
18681868
}
18691869

18701870
def typedAheadRhs(pt: Type) =

compiler/src/dotty/tools/dotc/typer/Typer.scala

+4-4
Original file line numberDiff line numberDiff line change
@@ -1782,7 +1782,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
17821782
// see tests/pos/i12226 and issue #12226. It might be possible that this
17831783
// will end up taking too much memory. If it does, we should just limit
17841784
// how much GADT constraints we infer - it's always sound to infer less.
1785-
pat1.putAttachment(InferredGadtConstraints, ctx.gadt.gadt)
1785+
pat1.putAttachment(InferredGadtConstraints, ctx.gadt)
17861786
if (pt1.isValueType) // insert a cast if body does not conform to expected type if we disregard gadt bounds
17871787
body1 = body1.ensureConforms(pt1)(using originalCtx)
17881788
assignType(cpy.CaseDef(tree)(pat1, guard1, body1), pat1, body1)
@@ -2362,7 +2362,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
23622362
ctx.outer.outersIterator.takeWhile(!_.owner.is(Method))
23632363
.filter(ctx => ctx.owner.isClass && ctx.owner.typeParams.nonEmpty)
23642364
.toList.reverse
2365-
.foreach(ctx => rhsCtx.gadt.addToConstraint(ctx.owner.typeParams))
2365+
.foreach(ctx => rhsCtx.gadtState.addToConstraint(ctx.owner.typeParams))
23662366

23672367
if tparamss.nonEmpty then
23682368
rhsCtx.setFreshGADTBounds
@@ -2371,7 +2371,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
23712371
// we're typing a polymorphic definition's body,
23722372
// so we allow constraining all of its type parameters
23732373
// constructors are an exception as we don't allow constraining type params of classes
2374-
rhsCtx.gadt.addToConstraint(tparamSyms)
2374+
rhsCtx.gadtState.addToConstraint(tparamSyms)
23752375
else if !sym.isPrimaryConstructor then
23762376
linkConstructorParams(sym, tparamSyms, rhsCtx)
23772377

@@ -3835,7 +3835,7 @@ class Typer(@constructorOnly nestingLevel: Int = 0) extends Namer
38353835
adaptToSubType(wtp)
38363836
case CompareResult.OKwithGADTUsed
38373837
if pt.isValueType
3838-
&& !inContext(ctx.fresh.setGadt(GadtConstraintHandling(GadtConstraint.empty))) {
3838+
&& !inContext(ctx.fresh.setGadtState(GadtState(GadtConstraint.empty))) {
38393839
val res = (tree.tpe.widenExpr frozen_<:< pt)
38403840
if res then
38413841
// we overshot; a cast is not needed, after all.

compiler/src/scala/quoted/runtime/impl/QuotesImpl.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -3130,7 +3130,7 @@ class QuotesImpl private (using val ctx: Context) extends Quotes, QuoteUnpickler
31303130
if typeHoles.isEmpty then ctx
31313131
else
31323132
val ctx1 = ctx.fresh.setFreshGADTBounds.addMode(dotc.core.Mode.GadtConstraintInference)
3133-
ctx1.gadt.addToConstraint(typeHoles)
3133+
ctx1.gadtState.addToConstraint(typeHoles)
31343134
ctx1
31353135

31363136
val matchings = QuoteMatcher.treeMatch(scrutinee, pat1)(using ctx1)

0 commit comments

Comments
 (0)