Back to Intellij Community

BoxingBoxedValue

java/java-impl/resources/inspectionDescriptions/BoxingBoxedValue.html

2025.3-rc-2376 B
Original Source

Reports boxing of already boxed values.

This is a redundant operation since any boxed value will first be auto-unboxed before boxing the value again. If done inside an inner loop, such code may cause performance problems.

Example:

Integer value = 1;
  method(Integer.valueOf(value));

After the quick fix is applied:

Integer value = 1;
  method(value);