commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pascalschumac...@apache.org
Subject [lang] LANG-1188: StringUtils#join(T...): warning: [unchecked] Possible heap pollution from parameterized vararg type T
Date Sun, 23 Oct 2016 19:59:27 GMT
Repository: commons-lang
Updated Branches:
  refs/heads/master 23108b1bd -> d6644e4fb


LANG-1188: StringUtils#join(T...): warning: [unchecked] Possible heap pollution from parameterized
vararg type T

fixed by adding @SafeVarargs


Project: http://git-wip-us.apache.org/repos/asf/commons-lang/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-lang/commit/d6644e4f
Tree: http://git-wip-us.apache.org/repos/asf/commons-lang/tree/d6644e4f
Diff: http://git-wip-us.apache.org/repos/asf/commons-lang/diff/d6644e4f

Branch: refs/heads/master
Commit: d6644e4fbe3d125eed2d85e58fc7133466042f10
Parents: 23108b1
Author: pascalschumacher <pascalschumacher@gmx.net>
Authored: Sun Oct 23 21:59:11 2016 +0200
Committer: pascalschumacher <pascalschumacher@gmx.net>
Committed: Sun Oct 23 21:59:11 2016 +0200

----------------------------------------------------------------------
 src/changes/changes.xml                                 | 1 +
 src/main/java/org/apache/commons/lang3/StringUtils.java | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-lang/blob/d6644e4f/src/changes/changes.xml
----------------------------------------------------------------------
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index baec0b8..b73f6bc 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -46,6 +46,7 @@ The <action> type attribute can be add,update,fix,remove.
   <body>
 
   <release version="3.6" date="2016-MM-DD" description="TBD">
+    <action issue="LANG-1188" type="fix" dev="paschuma">StringUtils#join(T...): warning:
[unchecked] Possible heap pollution from parameterized vararg type T</action>
     <action issue="LANG-1144" type="fix" dev="ggregory" due-to="Waldemar Maier, Gary Gregory">Multiple
calls of org.apache.commons.lang3.concurrent.LazyInitializer.initialize() are possible.</action>
     <action issue="LANG-1276" type="fix" dev="pschumacher" due-to="Andy Klimczak">StrBuilder#replaceAll
ArrayIndexOutOfBoundsException</action>
     <action issue="LANG-1278" type="fix" dev="pschumacher" due-to="Duke Yin">BooleanUtils
javadoc issues</action>

http://git-wip-us.apache.org/repos/asf/commons-lang/blob/d6644e4f/src/main/java/org/apache/commons/lang3/StringUtils.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/lang3/StringUtils.java b/src/main/java/org/apache/commons/lang3/StringUtils.java
index ce2f92d..dba1a3a 100644
--- a/src/main/java/org/apache/commons/lang3/StringUtils.java
+++ b/src/main/java/org/apache/commons/lang3/StringUtils.java
@@ -3753,6 +3753,7 @@ public class StringUtils {
      * @since 2.0
      * @since 3.0 Changed signature to use varargs
      */
+    @SafeVarargs
     public static <T> String join(final T... elements) {
         return join(elements, null);
     }


Mime
View raw message