-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Fix #6538: Make interfaces.SourcePosition resilient to missing sources #6573
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think pointer
and pointerSpace
should return an empty Optional if we don't have a source.
@@ -86,7 +86,9 @@ public void doReport(MessageContainer cont, Context ctx) { | |||
return Optional.ofNullable(src.file().path()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be clearer to use if (src.exists())
, same for sourceFile
above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@smarter could you have a look at the last two commits that add your suggestions |
No description provided.