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

Scala Compilation Issue #1572

Open
parkerirving45 opened this issue Oct 24, 2024 · 2 comments
Open

Scala Compilation Issue #1572

parkerirving45 opened this issue Oct 24, 2024 · 2 comments
Assignees

Comments

@parkerirving45
Copy link

Describe the bug?

On any version greater than 13.0.2 I get this compilation issue

[error]   bad constant pool index: 0 at pos: 1942
[error]      while compiling: /Staff.scala
[error]         during phase: globalPhase=typer, enteringPhase=parser
[error]      library version: version 2.12.16
[error]     compiler version: version 2.12.16
[error] == Source file context for tree position ==
[error] 
[error]     28         case _ => EmploymentType.Contigent;
[error]     29       },
[error]     30       managerEmail = user.getProfile.getManager,
[error]     31       employmentStatus = user.getStatus.toString match {
[error]     32         case "ACTIVE" => EmploymentStatus.Active;
[error]     33         case "DEPROVISIONED" => EmploymentStatus.Deprovisioned;
[error]     34         case "PROVISIONED" => EmploymentStatus.Provisioned;

I am on scala version 2.12 and using Java 11.0.18. In the docs it mentions you need to use Java 11+ which I am using. The compilation issue goes away if I remove any calls to UserStatus or getStatus when on version 19.0.2. It also goes away when I run version 13.0.2.

What is expected to happen?

Should compile successfully

What is the actual behavior?

Compilation fails with error above

Reproduction Steps?

Run a scala sbt project on scala 2.12 and java version 11 and then try and access User.getStatus

Additional Information?

No response

Java Version

11.0.18

SDK Version

19.0.2

OS version

No response

@arvindkrishnakumar-okta
Copy link
Contributor

Could this be an IDE thing? which IDE are you using and can you refresh the dependencies and try reloading the project?

@parkerirving45
Copy link
Author

Could this be an IDE thing? which IDE are you using and can you refresh the dependencies and try reloading the project?

This is happening when running sbt compile from the command line not within an IDE

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants