-
Notifications
You must be signed in to change notification settings - Fork 638
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
@Cleanup support #287
Comments
Hello! We added extension point( |
Hello @sirgl , Unfortunately it will not fix current issue, because it's something else. Here I need some extension point to give IntelliJ a hint, that some line of code will actually produce an exception. Code example:
Code after lombok processing:
Do you have some suggestions, how to make it working? Or can you provide some additional extension points? |
Hello, I see that this annotation is not in the supported list.
Do you plan to support it?
At the moment it can generate fake errors in the IDE for code like this:
try { @Cleanup InputStream profileIs = Thread.currentThread().getContextClassLoader().getResourceAsStream(PROFILE_CONTEXT); } catch (IOException e) { throw new CustomException(e); }
This code is correct and Eclipse accepts it, Intellij says that the IOException is never thrown but is not correct, is thrown by InputStream.close().
(I know that in this specific case AutoClosable should be used, but it's not always possible).
The text was updated successfully, but these errors were encountered: