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

Add contracts to some ItemUtils #605

Closed
wants to merge 1 commit into from

Conversation

Protonull
Copy link
Contributor

Sometimes IDEs will fret if you use an item after doing an if (ItemUtils.isEmptyItem(item)) return; because it doesn't know that the method is also a null check. These contracts will placate the IDE, removing the warnings, resulting in less confusion and less bytecode.

Sometimes IDEs will fret if you use an item after doing an `if (ItemUtils.isEmptyItem(item)) return;` because it doesn't know that the method is also a null check. These contracts will placate the IDE, removing the warnings, resulting in less confusion and less bytecode.
@Protonull Protonull closed this Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

1 participant