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 Implicit Conversion eg from Int to Long Causes the Int token to lack Precise Code Intelligence #412

Closed
wchau opened this issue Mar 4, 2022 · 2 comments · Fixed by #472
Assignees

Comments

@wchau
Copy link

wchau commented Mar 4, 2022

lsif-java version: 0.7.7

Type of code: Implicit Conversion from Int to Long

Expected behavior: When an Int var / val is used as a Long parameter or converted to Long, Precise Code Intelligence should still work on the Int var / val.

Actual behavior: Definition Code Intelligence is missing. When "Find References" is clicked, ALL implicit Int to Long conversions show up in Precise Code Intelligence.

val a: Int = 5
val b: Long = a

a is lacking correct Precise Code Intelligence

def a(b: Long): Unit = {
...
}
...
val b: Int = 5
a(b)

b is lacking correct Precise Code Intelligence

I haven't tried it, but presumably, Float and Double may have the same issue (and maybe other implicit conversions I am unaware of)

@olafurpg
Copy link
Member

Thank you for reporting! This is in fact a duplicate of this issue here scalameta/scalameta#1431 from 2018 😄

Pending upstream fix in semanticdb-scalac scalameta/scalameta#2797 I'll close this issue once there's a new version of semanticdb-scalac available.

@olafurpg
Copy link
Member

Confirming that the navigation works as expected when using SCIP.

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

Successfully merging a pull request may close this issue.

2 participants