-
Notifications
You must be signed in to change notification settings - Fork 453
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
No report for two Classes in the same package with same name #1111
Comments
Eclipse reports Update: vscode-java reports it as well but there's still a bug. C1.java
C2.java
Open up I see : [Trace - 23:21:11] Received notification 'textDocument/publishDiagnostics'.
Params: {
"uri": "file:///tmp/foo/org/example/C2.java",
"diagnostics": [
{
"range": {
"start": {
"line": 3,
"character": 6
},
"end": {
"line": 3,
"character": 10
}
},
"severity": 1,
"code": "0",
"source": "Java",
"message": "The type Same is already defined"
}
]
} Now open up [Trace - 23:23:11] Received notification 'textDocument/publishDiagnostics'.
Params: {
"uri": "file:///tmp/foo/org/example/C2.java",
"diagnostics": []
} The message disappears. Looking at https://github.com/eclipse-jdt/eclipse.jdt.core/blob/35bf3605e3a1fba5c0864479d04fef13452f9046/org.eclipse.jdt.core.compiler.batch/src/org/eclipse/jdt/internal/compiler/lookup/CompilationUnitScope.java#L170-L177 it almost seems like |
If one uses It seems like a diagnostic that requires a full build is placed on a single file, so the way to persist it is probably to set the URI for the diagnostic as that of the project. |
Just as the title says, eclipse will report it.
Environment
Steps To Reproduce
Current Result
No problem dectected.
Fail to build.
The text was updated successfully, but these errors were encountered: