-
Notifications
You must be signed in to change notification settings - Fork 7
Code that is @AnnotatedFor("nullness")
is also @AnnotatedFor("initialization")
#92
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
Code that is @AnnotatedFor("nullness")
is also @AnnotatedFor("initialization")
#92
Conversation
Note: make the annotatedfor element follow alphabetical order |
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.
Adding some more explanation to the PR description would make it easier to reconstruct the point of the PR in the future.
As discussed, alphabetically sorting the checkers in AnnotatedFor
would be good. Is the IDE support that could do this? Could we have a simple Error Prone checker that looks for this and fixes it automatically?
@AnnotatedFor
nullness is also @AnnotatedFor
initialization
@AnnotatedFor
nullness is also @AnnotatedFor
initialization@AnnotatedFor("nullness")
is also @AnnotatedFor("initialization")
@wmdietl Let me fix the CI failure first. Since this looks like a format issue, will an additional |
@wmdietl I am not sure why I can not assign you in this repo so I pin here. I hope this can go into release and we shall update CF in AWS. |
Don't merge at the moment as annotatedfor('initialization') did not work correctly. See eisop/checker-framework#982 |
@Ao-senXiong Once https://github.com/eisop/checker-framework/pulls/985 and eisop/checker-framework#991 are merged, can this be merged? |
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.
Thanks!
@@ -42,7 +42,9 @@ | |||
import java.net.URISyntaxException; | |||
import java.nio.file.FileStore; | |||
import java.nio.file.FileSystems; | |||
import java.nio.file.LinkOption; |
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.
Why are the additional imports needed?
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.
Ah, I think ide must do this automatically... I never did that myself. I see a few places in the comment. I will remove them.
Co-authored-by: Werner Dietl <[email protected]>
`getGenericSignature()` is not documented well, but I noticed that `getGenericType()` compares the result of `getGenericSignature()` against `null`, so that got me to verify that it can in fact return `null`: ``` public class RecordComponentGenericSignature { record Rec(String s) {} public static void main(String[] args) { System.out.println(Rec.class.getRecordComponents()[0].getGenericSignature()); } } ```
@Ao-senXiong I just saw this file that is only Is there a reason for this? Also, please add a comment somewhere that when somebody adds nullness annotations, they should also think about adding initialization. |
I have Created #120 and eisop/checker-framework#1151 for above tasks. |
No description provided.