-
Bug
-
Resolution: Fixed
-
P5
-
8
JLS 12.5 has always said: "Execution of a string concatenation operator (§15.18.1) that is not part of a constant expression (§15.28) sometimes creates a new String object to represent the result."
However, the "sometimes" appears wrong; 15.18.1 requires that a new String is always created for a + that isn't a constant expression. See http://mail.openjdk.java.net/pipermail/compiler-dev/2014-January/008451.html
However, the "sometimes" appears wrong; 15.18.1 requires that a new String is always created for a + that isn't a constant expression. See http://mail.openjdk.java.net/pipermail/compiler-dev/2014-January/008451.html