I recently inherited a bunch of code that uses Java Integer, for which I am getting a lot of compiler warnings. I would like to convert these to int to eliminate the warnings (rather than suppress them). My question is...are there any issues with simply changing Integer declarations to int? Naturally I will test the code changes, but want to know ahead of time if I will be facing any issues. I am using Java version 17.
- The Overflow Blog
-
-
- Featured on Meta
-
-
-
Linked
Related
Hot Network Questions
- SF book series about a wandering space monk called Brother Paul
- Why does the final -ts in 'les États-Unis' produce a /z/ liaison sound rather than /t/ or /s/?
- Minimum width to connect both sides
- the profile of what I expected
- Effective resistance of a finite grid of resistor
- Why does D.J. translate "liberate me" as "save me"?
- Can military personnel disobey illegal orders under U.S. law?
- A Sequence of Words
- Refactor AI code for a forest diagram
- Cutting a Möbius strip in thirds. Why are the resulting strips interlinked?
- Find all integers n such that the sum of the factorials of its digits equals ⌊√n⌋
- Why are Jeremy Crawford's rules comments unreliable?
- How to automatically refresh or reload Import CSV node data?
- Is time an event?
- Were Biblical “Servants” Essentially Slaves?
- How much storage space do I really have?
- Instrumental parts page size, 8.5x11 or 9x12?
- Why are novel, easier music notation systems not widely accepted?
- Difference between these 2 different ways of extracting files from a zip archive
- Descriptive Grid
- Automatic (but deactivatable) language switching when typing cyrillic
- Does Hebrew really have 7 words for gold?
- Dactylic hexameter composition feedback
- Why didn't Yitzchak ask Rivka to say that she is his sister in the same fashion that Avraham did?
lang-java
Integeris a type of object, whileintis not, so if any of the code relies on one of these things being an object, that might cause an issue.intis program language neutral, whereas Integer is Java only. Objects are also much larger in memory than primatives