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

Cleanup redundant cast warnings.. #5992

Merged
merged 1 commit into from
May 27, 2023

Conversation

BradWalker
Copy link
Member

As a result of much of the warning cleanup work I've done over the past couple of years, the redundant cast warnings start happening more fequently.

   [repeat] /home/bwalker/src/netbeans/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/ButtonPopupSwitcher.java:344: warning: [cast] redundant cast to Item
   [repeat]                 final Item item = ( Item ) pTable.getSelectedItem();
   [repeat]                                   ^

This works reduces those warnings.

As a result of much of the warning cleanup work I've done over the past couple of years, the redundant cast warnings start happening more fequently.

   [repeat] /home/bwalker/src/netbeans/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/ButtonPopupSwitcher.java:344: warning: [cast] redundant cast to Item
   [repeat]                 final Item item = ( Item ) pTable.getSelectedItem();
   [repeat]                                   ^

This works reduces those warnings.
@BradWalker BradWalker added this to the NB19 milestone May 26, 2023
@BradWalker BradWalker self-assigned this May 26, 2023
@mbien
Copy link
Member

mbien commented May 26, 2023

hi @BradWalker. PRs like this one here do always require the ci:all-tests [ci] enable all tests label. Since they change code across the repository.

more info on how CI works is on the wiki

@BradWalker BradWalker added the ci:all-tests [ci] enable all tests label May 26, 2023
@BradWalker
Copy link
Member Author

Thanks for the feedback/pointer. I wasn't aware of this.

@mbien
Copy link
Member

mbien commented May 26, 2023

no worries brad. Also, restarting existing workflows won't take changes in labels into account unfortunately. We have a secret button which forces a new workflow though which I will now use :)

@apache apache locked and limited conversation to collaborators May 26, 2023
@apache apache unlocked this conversation May 26, 2023
Copy link
Contributor

@matthiasblaesing matthiasblaesing left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. You might consider removing the new Integer() calls in TableElementImpl.java and rely on autoboxing.

@BradWalker BradWalker merged commit 711207c into apache:master May 27, 2023
@BradWalker BradWalker deleted the cleanup_redundant_casts branch May 27, 2023 06:08
@BradWalker
Copy link
Member Author

Looks good to me. You might consider removing the new Integer() calls in TableElementImpl.java and rely on autoboxing.

Hey @matthiasblaesing , I'm getting ready to clean up the few remaining calls to new Integer().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci:all-tests [ci] enable all tests Code cleanup
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants