Inconsistent hygiene of type parameters and parameter types of case apply / unapply / copy #8884
Labels
fixed in Scala 3
This issue does not exist in the Scala 3 compiler (https://github.com/lampepfl/dotty/)
Milestone
The parameter types of case class apply / unapply are not hygienic
The parameter types of
copy
are hygienic. This is inconsistent, and also the implementation is very complex (custom type completer). Hygiene was required forcopy
because it fails more often, namely in this exampleNote that B extends A, so the constructor parameter is
A.this.C
, while the copy parameter isB.this.C
.Type parameters of copy are not hygienic, as shown in this example:
Fixing this bug also requires clarifying the corresponding section in the spec
The text was updated successfully, but these errors were encountered: