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

[1.5.x] Make accessing OriginalTree noop on Scala 2.12.0-2 #997

Merged

Conversation

dwijnand
Copy link
Member

No description provided.

@dwijnand dwijnand linked an issue Jul 27, 2021 that may be closed by this pull request
@dwijnand dwijnand requested a review from retronym July 27, 2021 13:06
@retronym
Copy link
Member

retronym commented Jul 28, 2021

[error] ## Exception when compiling 3 sources to C:\Users\RUNNER~1\AppData\Local\Temp\sbt_d2cc00f6\p1\classes
[error] java.lang.ClassCastException: scala.tools.nsc.typechecker.StdAttachments$OriginalTreeAttachment cannot be cast to scala.runtime.Nothing$
[error] xsbt.Compat$OriginalTreeTraverser$Reflective$.traverseOriginal(Compat.scala:49)
[error] xsbt.Compat.processOriginalTreeAttachment(Compat.scala:25)
[error] xsbt.ExtractUsedNames$ExtractUsedNamesTraverser.handleClassicTreeNode(ExtractUsedNames.scala:294)
[error] xsbt.ExtractUsedNames$ExtractUsedNamesTraverser.traverse(ExtractUsedNames.scala:170)
[error] xsbt.ExtractUsedNames$ExtractUsedNamesTraverser.traverse(ExtractUsedNames.scala:164)
[error] scala.reflect.internal.Trees.$anonfun$itraverse$1(Trees.scala:1279)
[error] scala.reflect.api.Trees$Traverser.atOwner(Trees.scala:2515)

I've pushed an attempted fix

@dwijnand dwijnand requested a review from eed3si9n July 29, 2021 20:32
@eed3si9n eed3si9n changed the title Make accessing OriginalTree noop on Scala 2.12.0-2 [1.5.x] Make accessing OriginalTree noop on Scala 2.12.0-2 Jul 29, 2021
Copy link
Member

@eed3si9n eed3si9n left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Could you forward port this to develop as well?

@dwijnand dwijnand merged commit 3317556 into sbt:1.5.x Jul 29, 2021
@dwijnand dwijnand deleted the bring-back-OriginalTreeAttachment-support branch July 29, 2021 20:39
@dwijnand
Copy link
Member Author

Oh, yeah. Of course.

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.

Scala 2.12.0 ~ 2.12.2 no longer works
3 participants