Skip to content

Fix a typo that caused unnecessary cache invalidation #4259

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

Merged
merged 1 commit into from
Apr 15, 2018
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion compiler/src/dotty/tools/dotc/core/Phases.scala
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ object Phases {
myRefChecked = prev.getClass == classOf[RefChecks] || prev.refChecked
myLabelsReordered = prev.getClass == classOf[LabelDefs] || prev.labelsReordered
mySameMembersStartId = if (changesMembers) id else prev.sameMembersStartId
mySameParentsStartId = if (changesParents) id else prev.sameMembersStartId
mySameParentsStartId = if (changesParents) id else prev.sameParentsStartId
}

protected[Phases] def init(base: ContextBase, id: Int): Unit = init(base, id, id)
Expand Down
4 changes: 3 additions & 1 deletion compiler/src/dotty/tools/dotc/transform/ElimByName.scala
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ class ElimByName extends TransformByNameApply with InfoTransformer {
override def runsAfterGroupsOf = Set(Splitter.name)
// I got errors running this phase in an earlier group, but I did not track them down.

override def changesParents: Boolean = true // Only true for by-names

/** Map `tree` to `tree.apply()` is `ftree` was of ExprType and becomes now a function */
private def applyIfFunction(tree: Tree, ftree: Tree)(implicit ctx: Context) =
if (isByNameRef(ftree))
Expand Down Expand Up @@ -82,4 +84,4 @@ class ElimByName extends TransformByNameApply with InfoTransformer {

object ElimByName {
val name = "elimByName"
}
}