Skip to content

Replace erased class modifiers with Erased base traits #23447

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

Open
wants to merge 19 commits into
base: main
Choose a base branch
from

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Jun 28, 2025

Based on #23419

@odersky odersky marked this pull request as draft June 28, 2025 18:48
@odersky odersky requested a review from EugeneFlesselle June 30, 2025 13:36
@odersky
Copy link
Contributor Author

odersky commented Jun 30, 2025

Doc pages are now updated to the new scheme. See c878878.

@odersky odersky marked this pull request as ready for review July 6, 2025 15:33
odersky added 19 commits July 6, 2025 17:34
Since we will force erased expressions to be pure values, they are always
initialized.
# Conflicts:
#	compiler/src/dotty/tools/dotc/ast/TreeInfo.scala
 - erasedValue[<ConstantType>] is now considered to be pure
 - calls of synthetic case class apply are considered pure if the case
   class is NoInits
 - Companions of Scala-2 classes Tuple and Some are assumed to be NoInits
Drop the previous convention that Singleton is an erased class under
x.modularity. That does not work anynmore if we change to the Erased trait
scheme.
Replace with test whether a type derivesFrom Erased.
We should never have flaky tests. Please, everyone adding new tests, watch out for this.
@odersky odersky force-pushed the change-erased-3 branch from c878878 to c43b83d Compare July 6, 2025 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants