Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adapt toInstantiate in interpolateTypeVars to consider #20399 #20426

Merged
merged 1 commit into from
May 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion compiler/src/dotty/tools/dotc/typer/Inferencing.scala
Original file line number Diff line number Diff line change
Expand Up @@ -706,7 +706,9 @@ trait Inferencing { this: Typer =>
else
typr.println(i"no interpolation for nonvariant $tvar in $state")
)
buf.toList
// constrainIfDependentParamRef could also have instantiated tvars added to buf before the check
buf.filterNot(_._1.isInstantiated).toList
end toInstantiate

def typeVarsIn(xs: ToInstantiate): TypeVars =
xs.foldLeft(SimpleIdentitySet.empty: TypeVars)((tvs, tvi) => tvs + tvi._1)
Expand Down
Loading